Hello-QM/catgo-LRG / server/catgo/workflow
catgo-workflow
VerifiedCreate and manage computational chemistry workflows with CatGo. Supports VASP, CP2K, ORCA, MLP, LAMMPS. Build OER/HER/CO2RR workflows, geometry optimization, frequency analysis, Gibbs energy calculations.
engine/engine_registry.py
View on GitHub"""Pluggable engine registry — add new software without modifying submitter/collector.
Two registries:
@register_engine("vasp") — input generation (INCAR/POSCAR/KPOINTS)
@register_collector("vasp") — result collection (read OUTCAR/CONTCAR)
Adding a new software = register two functions, nothing else to change.
"""
from __future__ import annotations
import logging
from typing import Any, Callable, Awaitable
logger = logging.getLogger(__name__)
EngineGenerator = Callable[..., Awaitable[None]]
ResultCollector = Callable[..., Awaitable[dict]]
_ENGINE_REGISTRY: dict[str, EngineGenerator] = {}
_COLLECTOR_REGISTRY: dict[str, ResultCollector] = {}
def register_engine(engine_key: str):
"""Decorator to register an input generator for a software engine."""
def decorator(func: EngineGenerator) -> EngineGenerator:
_ENGINE_REGISTRY[engine_key] = func
return func
return decorator
def register_collector(engine_key: str):
"""Decorator to register a result collector for a software engine."""
def decorator(func: ResultCollector) -> ResultCollector:
_COLLECTOR_REGISTRY[engine_key] = func
return func
return decorator
def get_engine_generator(engine_key: str) -> EngineGenerator | None:
return _ENGINE_REGISTRY.get(engine_key)
def get_result_collector(engine_key: str) -> ResultCollector | None:
return _COLLECTOR_REGISTRY.get(engine_key)
def list_engines() -> list[str]:
return list(_ENGINE_REGISTRY.keys())
def list_collectors() -> list[str]:
return list(_COLLECTOR_REGISTRY.keys())
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| planning-and-task-breakdownaddyosmani/agent-skillsBreaks work into ordered tasks. Use when you have a spec or clear requirements and need to break work into implementable tasks. Use when a task feels too large to start, when you need to estimate scope, or when parallel work is possible. | Stars: 119k | Updated | Claude CodeCodex | Verified | Install |
| screenpipethedotmack/claude-memSearch screen and audio history recorded by Screenpipe and optionally save selected context into claude-mem. Use when the user asks to recall desktop activity, a meeting, or something seen in another app through Screenpipe. | Stars: 118k | Updated | Claude CodeCodex | Verified | Install |
| contact-widgetnexu-io/open-designSelf-contained floating chat widget with welcome screen, social links, meeting button, and message input. Single HTML file, zero dependencies. | Stars: 108k | Updated | Claude CodeCodex | Verified | Install |
| meeting-notesnexu-io/open-designMeeting notes page — title bar with attendees, agenda checklist, decisions block, action items table with owners + dates, and a "next meeting" footer. Use when the brief mentions "meeting notes", "minutes", "1:1 notes", "all-hands recap", or "会议纪要". | Stars: 108k | Updated | Claude CodeCodex | Verified | Install |