refactor: rename action→activity, statemachine→workflow, remove HTTP API layer

- action/ → activity/ (Temporal activities)
- statemachine/ → workflow/ (Temporal workflows)
- Removed internal/api/ and cmd/server/ (api-gw handles HTTP, Temporal is the API)
- Created pkg/types/types.go as single source of truth for all shared types
- Extracted CallRoleLLM helper (DRY: implementer/planner/judge shared pattern)
- Fixed circular import: workflow_graph_query uses string activity names
- Fixed logger.logf → logger.Info/Warn (method didn't exist)
- Fixed routing types: added Branches, Activity, BackoffSeconds, TaskActivity
- Fixed db.Canvas.Name, db.Client→DB, GetWorkflow→FetchWorkflow
- Removed unused imports
- All tests pass, build clean, vet clean
This commit is contained in:
Test
2026-09-05 23:59:13 -07:00
parent c228b54fd7
commit 9c9e9450bc
54 changed files with 847 additions and 1901 deletions
+21
View File
@@ -0,0 +1,21 @@
package activity
import "github.com/rockliang/poimen/workflows/pkg/types"
// Re-export from pkg/types for convenience within activity package.
type ModelSpec = types.ModelSpec
type PromptSpec = types.PromptSpec
type SkillRef = types.SkillRef
type OrchestratorConfig = types.OrchestratorConfig
type TaskUnitOutput = types.TaskUnitOutput
type EdgeWithWording = types.EdgeWithWording
type RelationWording = types.RelationWording
type CanvasWithRelationsData = types.CanvasWithRelationsData
type FetchCanvasRelationsInput = types.FetchCanvasRelationsInput
type CanvasReasonerInput = types.CanvasReasonerInput
type GraphRAGQueryInput = types.GraphRAGQueryInput
type GraphRAGQueryOutput = types.GraphRAGQueryOutput
type QueryPathData = types.QueryPathData
type CanvasCompatibilityInput = types.CanvasCompatibilityInput
type IndexGraphRAGInput = types.IndexGraphRAGInput
type IndexGraphRAGOutput = types.IndexGraphRAGOutput