Commit Graph

7 Commits

Author SHA1 Message Date
朝夕 81da2e9f81 wip: 对于用户模型进行了优化,增加了权限模型和权限校验 2026-04-21 23:00:59 +08:00
朝夕 3cf2411c4a wip: 修改了大量漏洞 2026-04-17 22:07:49 +08:00
朝夕 3a8b1e4054 wip: 优化bug 2026-04-17 19:43:32 +08:00
朝夕 2e5b2bce3a wip:更新版权 2026-04-10 10:50:25 +08:00
朝夕 2552017ea7 wip:对于api接口进行了完善,完善了global_state_machine(全局状态机),进行了大规模重构 2026-04-08 22:09:54 +08:00
朝夕 1bf3aaf154
Add workflow agent nodes, memory RAG, and tool plugin outlines (#1)
* Add workflow agent nodes, memory RAG, and tool plugin outlines

- Add MemoryRAG class integrated with PostgresDatabase.
- Rewrite SupervisoryNode, ConsciousnessNode, and ControlNode as ray remote actors with an injected pydantic_ai Agent.
- Create initial tool plugin scaffolding for RAG, web_crawler, and docker_sandbox.

Co-authored-by: zhaoxi826 <198742034+zhaoxi826@users.noreply.github.com>

* Flesh out workflow agent nodes, memory RAG, and tool plugins

- Added concrete SQLModel implementations for WorkflowRecord and MemoryRecord with pgvector support.
- Defined a `Workflow` Pydantic model for protocol communication.
- Implemented core agent run logic in SupervisoryNode, ConsciousnessNode, and ControlNode.
- Implemented actual basic httpx and docker-py logic for the tool plugins.

Co-authored-by: zhaoxi826 <198742034+zhaoxi826@users.noreply.github.com>

* Refactor node logic to use existing PretorWorkflow

- Deleted redundant `workflow.py` created earlier under `protocol/`.
- Updated `SupervisoryNode`, `ConsciousnessNode`, and `ControlNode` to correctly import and handle the existing `PretorWorkflow`, `WorkerGroup`, and `WorkStep` models from `pretor.core.workflow_manager.workflow`.

Co-authored-by: zhaoxi826 <198742034+zhaoxi826@users.noreply.github.com>

* Add UserEvent routing and fix SQLAlchemy execute syntax

- Added `UserEvent` class to `pretor.core.workflow_manager.workflow` to represent user interactions.
- Updated `SupervisoryNode.process_event` to receive the event, analyze complexity with the LLM, and either directly reply or dispatch a `ConsciousnessNode` workflow generation.
- Fixed SQLAlchemy AsyncSession methods in `memory.py` from `.exec()` to `.execute()`.

Co-authored-by: zhaoxi826 <198742034+zhaoxi826@users.noreply.github.com>

* Rename UserEvent to PretorEvent

- Renamed `UserEvent` to `PretorEvent` in `pretor/core/workflow_manager/workflow.py`.
- Updated references in `pretor/individual_plugin/supervisory_node/supervisory_node.py` to use `PretorEvent`.

Co-authored-by: zhaoxi826 <198742034+zhaoxi826@users.noreply.github.com>

---------

Co-authored-by: google-labs-jules[bot] <161369871+google-labs-jules[bot]@users.noreply.github.com>
Co-authored-by: zhaoxi826 <198742034+zhaoxi826@users.noreply.github.com>
2026-03-31 22:08:51 +08:00
朝夕 46937fbc10 feat:使用pytanticAI再次重构,增加了对于api的接口管理 2026-03-31 18:15:18 +08:00