Skip to content

Commit 2810b15

Browse files
engkimoclaude
andcommitted
feat: rebrand to Morphic-Agent, restructure to Clean Architecture
Remove legacy SynthepseAI codebase (core/, examples/, old docs). Add 4-layer Clean Architecture: domain/, application/, infrastructure/, interface/, tests/, ui/. See CLAUDE.md and docs/ARCHITECTURE.md. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
1 parent 3ef2bc3 commit 2810b15

684 files changed

Lines changed: 108619 additions & 23457 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.dockerignore

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
# Version control
2+
.git
3+
.gitignore
4+
5+
# Environment / secrets
6+
.env
7+
.env.local
8+
.env.*.local
9+
10+
# Python artifacts
11+
__pycache__
12+
*.pyc
13+
*.pyo
14+
*.egg-info
15+
.eggs
16+
dist
17+
build
18+
.venv
19+
venv
20+
21+
# Test / lint caches
22+
.pytest_cache
23+
.ruff_cache
24+
.mypy_cache
25+
htmlcov
26+
.coverage
27+
28+
# Node / frontend (handled by ui/Dockerfile separately)
29+
ui/node_modules
30+
ui/.next
31+
ui/.env.local
32+
node_modules
33+
34+
# IDE
35+
.vscode
36+
.idea
37+
*.swp
38+
*.swo
39+
40+
# Runtime data
41+
.morphic
42+
*.log
43+
44+
# Documentation (not needed in container)
45+
docs/
46+
*.md
47+
!CLAUDE.md
48+
!pyproject.toml

.env.example

Lines changed: 83 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,83 @@
1-
# OpenAI APIキー設定 (https://platform.openai.com/apikeys からAPIキーを取得)
2-
OPENAI_API_KEY=your_api_key_here
3-
# 使用するOpenAIモデル(デフォルト: gpt-5)
4-
OPENAI_MODEL=gpt-5
1+
# =============================================================================
2+
# Morphic-Agent — Environment Variables
3+
# =============================================================================
4+
# Copy this file to .env and fill in your values:
5+
# cp .env.example .env
6+
#
7+
# IMPORTANT: Never commit .env to version control.
8+
# =============================================================================
9+
10+
# ── LLM API Keys (all optional — Ollama alone is sufficient) ──────────
11+
ANTHROPIC_API_KEY=
12+
OPENAI_API_KEY=
13+
GOOGLE_GEMINI_API_KEY=
14+
15+
# ── Local LLM (Ollama) ───────────────────────────────────────────────
16+
# Set LOCAL_FIRST=true to prefer free local models over paid APIs.
17+
OLLAMA_BASE_URL=http://127.0.0.1:11434
18+
OLLAMA_DEFAULT_MODEL=qwen3:8b
19+
OLLAMA_CODING_MODEL=qwen3-coder:30b
20+
LOCAL_FIRST=true
21+
22+
# ── Agent CLI Orchestration ──────────────────────────────────────────
23+
OPENHANDS_BASE_URL=http://localhost:3000
24+
OPENHANDS_MODEL=claude-sonnet-4-6
25+
CLAUDE_CODE_SDK_ENABLED=true
26+
GEMINI_CLI_ENABLED=true
27+
CODEX_CLI_ENABLED=true
28+
AGENT_DEFAULT_ENGINE=claude_code
29+
30+
# ── Semantic Memory ──────────────────────────────────────────────────
31+
SEMANTIC_MEMORY_BACKEND=mem0
32+
MEM0_API_KEY=
33+
MEMORY_TARGET_TOKENS=800
34+
MEMORY_RETENTION_THRESHOLD=0.3
35+
36+
# ── Database ─────────────────────────────────────────────────────────
37+
# For local development (docker-compose.yml uses these defaults):
38+
DATABASE_URL=postgresql+asyncpg://morphic:morphic_dev@localhost:5432/morphic_agent
39+
DATABASE_URL_SYNC=postgresql://morphic:morphic_dev@localhost:5432/morphic_agent
40+
REDIS_URL=redis://localhost:6379
41+
NEO4J_URI=bolt://localhost:7687
42+
NEO4J_USER=neo4j
43+
NEO4J_PASSWORD=morphic_dev
44+
45+
# For production (docker-compose.prod.yml overrides these via service env):
46+
# POSTGRES_DB=morphic_agent
47+
# POSTGRES_USER=morphic
48+
# POSTGRES_PASSWORD=<strong-random-password>
49+
# NEO4J_PASSWORD=<strong-random-password>
50+
51+
# ── Cost Control ─────────────────────────────────────────────────────
52+
# Monthly budget in USD. Circuit breaker stops all API calls at 95%.
53+
DEFAULT_MONTHLY_BUDGET_USD=50
54+
DEFAULT_TASK_BUDGET_USD=1.0
55+
AUTO_DOWNGRADE_ON_BUDGET=true
56+
CACHE_BREAKPOINTS_ENABLED=true
57+
58+
# ── LAEE — Local Autonomous Execution Engine (v0.4) ──────────────────
59+
# Approval modes: full-auto | confirm-destructive | confirm-all
60+
LAEE_ENABLED=true
61+
LAEE_APPROVAL_MODE=confirm-destructive
62+
LAEE_AUDIT_LOG_PATH=.morphic/audit_log.jsonl
63+
LAEE_UNDO_ENABLED=true
64+
LAEE_MAX_CONCURRENT_SHELLS=10
65+
LAEE_BROWSER_HEADLESS=true
66+
LAEE_GUI_ENABLED=true
67+
LAEE_CRON_ENABLED=true
68+
69+
# ── MCP — Model Context Protocol ────────────────────────────────────
70+
# JSON array of server configs: [{"name": "...", "command": "...", "args": [...]}]
71+
MCP_ENABLED=true
72+
MCP_SERVERS=[]
73+
74+
# ── Application Settings ─────────────────────────────────────────────
75+
# Environments: development | production
76+
MORPHIC_AGENT_ENV=development
77+
AUTO_TOOL_INSTALL=false
78+
EVOLUTION_ENABLED=true
79+
PLANNING_MODE=interactive
80+
81+
# ── Production Deployment (docker-compose.prod.yml) ──────────────────
82+
# Nginx listen port on the host machine.
83+
# NGINX_PORT=80

.github/issue_seeds.json

Lines changed: 0 additions & 16 deletions
This file was deleted.

.github/labels.json

Lines changed: 0 additions & 7 deletions
This file was deleted.

.github/milestones.json

Lines changed: 0 additions & 6 deletions
This file was deleted.

.github/workflows/ci.yml

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
branches: [main]
6+
pull_request:
7+
branches: [main]
8+
9+
concurrency:
10+
group: ${{ github.workflow }}-${{ github.ref }}
11+
cancel-in-progress: true
12+
13+
jobs:
14+
lint:
15+
runs-on: ubuntu-latest
16+
steps:
17+
- uses: actions/checkout@v4
18+
- uses: astral-sh/setup-uv@v4
19+
with:
20+
version: "latest"
21+
- run: uv sync --extra dev
22+
- run: uv run ruff check .
23+
24+
unit-tests:
25+
runs-on: ubuntu-latest
26+
steps:
27+
- uses: actions/checkout@v4
28+
- uses: astral-sh/setup-uv@v4
29+
with:
30+
version: "latest"
31+
- run: uv sync --extra dev
32+
- run: uv run pytest tests/unit/ -v --tb=short
33+
34+
ui-build:
35+
runs-on: ubuntu-latest
36+
defaults:
37+
run:
38+
working-directory: ui
39+
steps:
40+
- uses: actions/checkout@v4
41+
- uses: actions/setup-node@v4
42+
with:
43+
node-version: "22"
44+
cache: npm
45+
cache-dependency-path: ui/package-lock.json
46+
- run: npm ci
47+
- run: npm run build
48+
49+
docker-build:
50+
runs-on: ubuntu-latest
51+
steps:
52+
- uses: actions/checkout@v4
53+
- name: Build API image
54+
run: docker build -t morphic-agent-api .
55+
- name: Build UI image
56+
run: docker build -t morphic-agent-ui ./ui

.github/workflows/issues.yml

Lines changed: 0 additions & 47 deletions
This file was deleted.

.github/workflows/labels.yml

Lines changed: 0 additions & 37 deletions
This file was deleted.

.github/workflows/milestones.yml

Lines changed: 0 additions & 37 deletions
This file was deleted.

0 commit comments

Comments
 (0)