⚡ Zed IDE Setup

Configure Zed as your SEA-powered development environment.


Architecture

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
┌──────────────────────────────────────────────────┐
│                  Zed IDE                          │
│  ┌──────────────────────────────────────────┐    │
│  │         SEA™ Agent (ACP Gateway)          │    │
│  │  ├── validate_specs                      │    │
│  │  ├── generate_code                       │    │
│  │  ├── query_knowledge                     │    │
│  │  └── chat                                │    │
│  └──────────────────┬───────────────────────┘    │
└─────────────────────┼────────────────────────────┘
                      │ JSON-RPC (stdio)
                      ▼
┌──────────────────────────────────────────────────┐
│            ACP Gateway (Python)                  │
│  libs/sea/adapters/acp/src/acp_gateway.py        │
│                                                  │
│  Routes to: SEA™ API, Knowledge Graph, Pipeline   │
└──────────────────────────────────────────────────┘

Complete Configuration

~/.config/zed/settings.json

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
{
  "agent": {
    "command": "python",
    "args": ["-m", "libs.sea.adapters.acp.src.cli"],
    "cwd": "/path/to/SEA™",
    "env": {
      "LLM_PROVIDER_URL": "http://localhost:8000",
      "OXIGRAPH_URL": "http://localhost:7878",
      "PYTHONPATH": "/path/to/SEA™"
    }
  },
  "language_servers": {
    "sea-dsl": {
      "command": ["./target/release/sea-lsp"],
      "languages": ["sea"],
      "initialization_options": {
        "a2a_bridge_url": "http://localhost:8090"
      }
    }
  },
  "lsp": {
    "sea-lsp": {
      "binary": {
        "path": "./target/release/sea-lsp"
      },
      "initialization_options": {
        "a2a_bridge_url": "http://localhost:8090"
      }
    }
  },
  "file_types": {
    "SEA™ DSL": ["sea"]
  },
  "context_servers": {
    "sea-mcp": {
      "command": "./target/release/sea-lsp",
      "args": ["--mcp"],
      "tools": ["get_hover", "get_diagnostics"]
    }
  }
}

Available Capabilities

validate_specs

Validate SEA-DSL specification files.

Input:

1
2
3
4
5
6
{
  "toolName": "validate_specs",
  "arguments": {
    "paths": ["docs/specs/shared/kernel.sea"]
  }
}

Output:

1
2
3
4
5
6
7
8
{
  "success": true,
  "result": {
    "valid": true,
    "errors": [],
    "paths_checked": 1
  }
}

generate_code

Generate code from specifications using the SEA™ pipeline.

Input:

1
2
3
4
5
6
7
{
  "toolName": "generate_code",
  "arguments": {
    "specId": "case-management",
    "options": { "language": "typescript" }
  }
}

Output:

1
2
3
4
5
6
7
8
9
10
{
  "success": true,
  "result": {
    "specId": "case-management",
    "files": [
      "libs/case-management/domain/src/gen/entities.ts",
      "libs/case-management/domain/src/gen/value-objects.ts"
    ]
  }
}

query_knowledge

Query the Knowledge Graph using SPARQL.

Input:

1
2
3
4
5
6
7
{
  "toolName": "query_knowledge",
  "arguments": {
    "sparql": "SELECT ?entity WHERE { ?entity a sea:Entity }",
    "context": "governance"
  }
}

Output:

1
2
3
4
5
6
7
8
9
10
{
  "success": true,
  "result": {
    "results": [
      { "entity": { "value": "sea:PolicyRule" } },
      { "entity": { "value": "sea:AuthorityBoundary" } }
    ],
    "source": "oxigraph"
  }
}

chat (Send Message)

Conversational interaction with SEA™ agent.

Input:

1
2
3
4
5
6
{
  "message": {
    "role": "user",
    "content": "Explain the MECE quadrant model"
  }
}

Output:

1
2
3
4
5
6
{
  "response": {
    "role": "agent",
    "content": "The MECE Quadrant Model organizes SEA™ into four complementary systems:\n\n1. **Soul (Axiological Nexus)**: Value alignment and ethical constraints\n2. **Mind (DomainForge™)**: Semantic meaning and domain modeling\n3. **Will (Evolutionary Kernel)**: Learning and adaptation\n4. **Body (Thermodynamic Substrate)**: Resource management and execution\n\nThese quadrants are integrated via SDS-028..."
  }
}

Keyboard Shortcuts

Configure in Zed keymap:

1
2
3
4
5
6
7
8
{
  "bindings": {
    "cmd-shift-v": "sea:validate_current_file",
    "cmd-shift-g": "sea:generate_from_spec",
    "cmd-shift-k": "sea:query_knowledge",
    "cmd-shift-a": "agent:toggle_panel"
  }
}

Workflow Examples

1. Spec-First Development

1
2
3
4
1. Open docs/specs/my-context/my-service.sea
2. Cmd+Shift+V → Validate spec
3. Cmd+Shift+G → Generate code
4. Review generated files in libs/my-context/

2. Knowledge Discovery

1
2
3
4
1. Open Agent Panel (Cmd+Shift+A)
2. Ask: "What policies apply to case mutations?"
3. Agent queries Knowledge Graph
4. Returns: List of POL-* policies with references

3. Debt Analysis

1
2
3
1. Open any TypeScript file
2. Ask: "Analyze this file for semantic debt"
3. Agent returns: Debt items with SDS-016 classifications

Troubleshooting

Issue Solution
Agent not appearing Check python --version (need 3.11+)
“httpx not found” Run pip install httpx rdflib
SPARQL queries fail Start Oxigraph: docker-compose up oxigraph
Validation errors Check file path is relative to SEA™ root

Debug Mode

1
2
3
# Run ACP gateway manually with debug output
cd /path/to/SEA™
python -m libs.sea.adapters.acp.src.cli 2>&1 | tee acp.log

Last Updated: January 2026