update
This commit is contained in:
@@ -0,0 +1,34 @@
|
||||
# AIPass Framework
|
||||
|
||||
Orchestration framework for autonomous AI agent ecosystems.
|
||||
|
||||
## Structure
|
||||
|
||||
- `src/aipass/` — All modules live here
|
||||
- 10 modules: drone, seedgo, prax, cli, flow, ai_mail, api, trigger, spawn, devpulse
|
||||
- 3-layer architecture per module: `apps/branch.py` (entry) + `apps/modules/` (logic) + `apps/handlers/` (impl)
|
||||
- `AIPASS_REGISTRY.json` — Branch registry at repo root
|
||||
|
||||
## Commands
|
||||
|
||||
```
|
||||
drone systems # List registered modules/branches
|
||||
drone @seedgo verify # Verify standards packs installed
|
||||
drone @seedgo audit aipass # Run standards audit on repo
|
||||
drone @module --help # Module help
|
||||
```
|
||||
|
||||
## Conventions
|
||||
|
||||
- All imports use pip namespace: `from aipass.{module}.apps.modules...`
|
||||
- No hardcoded paths — use `Path(__file__).parents[N]` or registry lookups
|
||||
- Each module has `.trinity/` (passport, local, observations) for identity/memory
|
||||
- Each module has `.aipass/branch_system_prompt.md` for AI context injection
|
||||
- Tests: `pytest` from repo root
|
||||
- Branch prompt hook loads context from CWD's `.aipass/branch_system_prompt.md`
|
||||
|
||||
## Dev Rules
|
||||
|
||||
- Never bare imports (`from flow.apps...`) — always `from aipass.flow.apps...`
|
||||
- Test in Docker for isolation verification (localhost:8080 code-server)
|
||||
- `pyproject.toml` defines CLI entry points: `drone`, `seedgo`
|
||||
|
||||
+12
-2
@@ -1,8 +1,8 @@
|
||||
{
|
||||
"metadata": {
|
||||
"version": "1.0.0",
|
||||
"last_updated": "2026-03-05",
|
||||
"total_branches": 9
|
||||
"last_updated": "2026-03-06",
|
||||
"total_branches": 10
|
||||
},
|
||||
"branches": [
|
||||
{
|
||||
@@ -35,6 +35,16 @@
|
||||
"created": "2026-03-05",
|
||||
"last_active": "2026-03-05"
|
||||
},
|
||||
{
|
||||
"name": "DEVPULSE",
|
||||
"path": "/home/aipass/aipass_business/AIPass/src/aipass/devpulse",
|
||||
"profile": "library",
|
||||
"description": "Orchestration hub for AIPass public repo. Manages dev notes, DPLANs, system status dashboards. The DEV_CENTRAL of AIPass.",
|
||||
"email": "@devpulse",
|
||||
"status": "active",
|
||||
"created": "2026-03-06",
|
||||
"last_active": "2026-03-06"
|
||||
},
|
||||
{
|
||||
"name": "DRONE",
|
||||
"path": "src/aipass/drone",
|
||||
|
||||
@@ -1,6 +1,44 @@
|
||||
# AIPass Framework
|
||||
|
||||
Orchestration for autonomous AI agent ecosystems.
|
||||
Orchestration framework for autonomous AI agent ecosystems.
|
||||
|
||||
- Uses `src/` layout. Run tests: `pytest`. Lint: `ruff check`.
|
||||
- Trinity Pattern is the memory dependency.
|
||||
## Structure
|
||||
|
||||
- `src/aipass/` — All modules live here
|
||||
- 10 modules: drone, seedgo, prax, cli, flow, ai_mail, api, trigger, spawn, devpulse
|
||||
- 3-layer architecture per module: `apps/branch.py` (entry) + `apps/modules/` (logic) + `apps/handlers/` (impl)
|
||||
- `AIPASS_REGISTRY.json` — Branch registry at repo root
|
||||
- `.trinity/` per module — passport.json, local.json, observations.json (identity + memory)
|
||||
- `.aipass/branch_system_prompt.md` per module — AI context injection
|
||||
|
||||
## Commands
|
||||
|
||||
```
|
||||
drone systems # List registered modules/branches
|
||||
drone @seedgo verify # Verify standards packs installed
|
||||
drone @seedgo audit aipass # Run standards audit on repo
|
||||
drone @module --help # Module help
|
||||
```
|
||||
|
||||
## Conventions
|
||||
|
||||
- All imports use pip namespace: `from aipass.{module}.apps.modules...`
|
||||
- No hardcoded paths — use `Path(__file__).parents[N]` or registry lookups
|
||||
- Tests: `pytest` from repo root
|
||||
- Lint: `ruff check`
|
||||
- Trinity Pattern is the memory dependency
|
||||
- `pyproject.toml` defines CLI entry points: `drone`, `seedgo`
|
||||
|
||||
## Dev Rules
|
||||
|
||||
- Never bare imports (`from flow.apps...`) — always `from aipass.flow.apps...`
|
||||
- Test in Docker for isolation verification (localhost:8080 code-server)
|
||||
- No paths referencing `/home/aipass/` — that's Dev-Pass, not AIPass
|
||||
|
||||
## DevPulse
|
||||
|
||||
DevPulse (`src/aipass/devpulse/`) is the orchestration hub for this repo. It coordinates work across modules, tracks status, and manages dev notes. It is to AIPass what DEV_CENTRAL is to Dev-Pass.
|
||||
|
||||
## Current State
|
||||
|
||||
All modules in "building" status — imports rewired from Dev-Pass to pip namespace, not fully tested yet. MPLAN-001 (in Dev-Pass dev_central) tracks all component status.
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
{
|
||||
"permissions": {
|
||||
"allow": [],
|
||||
"deny": [],
|
||||
"ask": []
|
||||
},
|
||||
"enabledMcpjsonServers": []
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
__pycache__/
|
||||
*.pyc
|
||||
*.pyo
|
||||
.env
|
||||
*.egg-info/
|
||||
.coverage
|
||||
htmlcov/
|
||||
.pytest_cache/
|
||||
.mypy_cache/
|
||||
dist/
|
||||
build/
|
||||
*.log
|
||||
*.tmp
|
||||
*.swp
|
||||
@@ -0,0 +1,51 @@
|
||||
# DEVPULSE
|
||||
|
||||
**Purpose:** Orchestration hub for AIPass public repo. Manages dev notes, DPLANs, system status dashboards. The DEV_CENTRAL of AIPass.
|
||||
**Module:** `aipass.devpulse`
|
||||
**Created:** 2026-03-06
|
||||
|
||||
---
|
||||
|
||||
## Overview
|
||||
|
||||
### What I Do
|
||||
|
||||
|
||||
### How I Work
|
||||
- **Entry Point:** `apps/devpulse.py`
|
||||
- **Pattern:** Auto-discovers and routes to modules
|
||||
|
||||
---
|
||||
|
||||
## Architecture
|
||||
|
||||
```
|
||||
DEVPULSE/
|
||||
├── apps/
|
||||
│ ├── devpulse.py # Entry point
|
||||
│ ├── modules/ # Business logic
|
||||
│ ├── handlers/ # Implementation
|
||||
│ └── plugins/ # Extensions
|
||||
├── docs/
|
||||
├── tests/
|
||||
├── passport.json # Identity
|
||||
├── local.json # Session history
|
||||
├── observations.json # Collaboration patterns
|
||||
└── README.md
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## Commands
|
||||
|
||||
*Configure after initialization*
|
||||
|
||||
---
|
||||
|
||||
## Integration Points
|
||||
|
||||
### Depends On
|
||||
|
||||
|
||||
### Provides To
|
||||
|
||||
@@ -0,0 +1 @@
|
||||
# DEVPULSE apps package
|
||||
@@ -0,0 +1,86 @@
|
||||
"""
|
||||
DEVPULSE Branch - Main Orchestrator
|
||||
|
||||
Auto-discovery architecture:
|
||||
- Scans modules/ directory for .py files with handle_command()
|
||||
- Routes commands to discovered modules automatically
|
||||
- No manual imports or routing needed
|
||||
"""
|
||||
|
||||
import sys
|
||||
import importlib
|
||||
from pathlib import Path
|
||||
from typing import List, Any
|
||||
|
||||
from aipass.prax import logger
|
||||
|
||||
# =============================================================================
|
||||
# MODULE DISCOVERY
|
||||
# =============================================================================
|
||||
|
||||
MODULES_DIR = Path(__file__).parent / "modules"
|
||||
|
||||
|
||||
def discover_modules() -> List[Any]:
|
||||
"""Auto-discover modules in modules/ directory."""
|
||||
modules = []
|
||||
|
||||
if not MODULES_DIR.exists():
|
||||
return modules
|
||||
|
||||
for file_path in MODULES_DIR.glob("*.py"):
|
||||
if file_path.name.startswith("_"):
|
||||
continue
|
||||
|
||||
module_name = f"apps.modules.{file_path.stem}"
|
||||
|
||||
try:
|
||||
module = importlib.import_module(module_name)
|
||||
if hasattr(module, "handle_command"):
|
||||
modules.append(module)
|
||||
except Exception as e:
|
||||
logger.error(f"[DEVPULSE] Failed to load module {module_name}: {e}")
|
||||
|
||||
return modules
|
||||
|
||||
|
||||
def route_command(command: str, args: List[str], modules: List[Any]) -> bool:
|
||||
"""Route command to appropriate module."""
|
||||
for module in modules:
|
||||
try:
|
||||
if module.handle_command(command, args):
|
||||
return True
|
||||
except Exception as e:
|
||||
logger.error(f"[DEVPULSE] Module {module.__name__} error: {e}")
|
||||
return False
|
||||
|
||||
|
||||
# =============================================================================
|
||||
# MAIN ENTRY POINT
|
||||
# =============================================================================
|
||||
|
||||
def main():
|
||||
"""Main entry point - routes commands or shows help."""
|
||||
modules = discover_modules()
|
||||
args = sys.argv[1:]
|
||||
|
||||
if len(args) == 0 or args[0] in ["--help", "-h", "help"]:
|
||||
print(f"DEVPULSE - {len(modules)} modules discovered")
|
||||
for module in modules:
|
||||
name = module.__name__.split(".")[-1]
|
||||
desc = (module.__doc__ or "").strip().split("\n")[0] if module.__doc__ else "No description"
|
||||
print(f" {name:20} {desc}")
|
||||
return 0
|
||||
|
||||
command = args[0]
|
||||
remaining = args[1:] if len(args) > 1 else []
|
||||
|
||||
if route_command(command, remaining, modules):
|
||||
return 0
|
||||
|
||||
print(f"Unknown command: {command}")
|
||||
return 1
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
sys.exit(main())
|
||||
@@ -0,0 +1,21 @@
|
||||
[pytest]
|
||||
# Test discovery paths
|
||||
testpaths = tests
|
||||
|
||||
# Test file patterns
|
||||
python_files = test_*.py
|
||||
python_functions = test_*
|
||||
python_classes = Test*
|
||||
|
||||
# Command-line options (always applied)
|
||||
addopts =
|
||||
-v # Verbose output
|
||||
--tb=short # Short traceback format
|
||||
--strict-markers # Raise error on unknown markers
|
||||
-ra # Show summary of all test outcomes
|
||||
|
||||
# Test markers (for categorizing tests)
|
||||
markers =
|
||||
unit: Unit tests
|
||||
integration: Integration tests
|
||||
slow: Tests that take significant time
|
||||
@@ -0,0 +1 @@
|
||||
# Tests package for devpulse
|
||||
@@ -0,0 +1,43 @@
|
||||
#!/home/aipass/.venv/bin/python3
|
||||
|
||||
# ===================AIPASS====================
|
||||
# META DATA HEADER
|
||||
# Name: tests/conftest.py
|
||||
# Date: 2025-11-08
|
||||
# Version: 1.0.0
|
||||
# Category: cortex/tests
|
||||
#
|
||||
# CHANGELOG (Max 5 entries):
|
||||
# - v1.0.0 (2025-11-08): Initial implementation - Shared pytest fixtures
|
||||
#
|
||||
# CODE STANDARDS:
|
||||
# - Error handling: Use error handler system (apps/handlers/error/)
|
||||
# =============================================
|
||||
|
||||
"""Shared pytest fixtures for cortex tests"""
|
||||
import pytest
|
||||
import shutil
|
||||
import tempfile
|
||||
from pathlib import Path
|
||||
from typing import Generator
|
||||
|
||||
|
||||
@pytest.fixture
|
||||
def temp_test_dir() -> Generator[Path, None, None]:
|
||||
"""Creates temporary directory for testing, cleans up after"""
|
||||
test_dir = Path(tempfile.mkdtemp())
|
||||
yield test_dir
|
||||
if test_dir.exists():
|
||||
shutil.rmtree(test_dir)
|
||||
|
||||
|
||||
@pytest.fixture
|
||||
def sample_test_data() -> dict:
|
||||
"""Provides sample test data
|
||||
|
||||
Customize this fixture for your module's needs
|
||||
"""
|
||||
return {
|
||||
"test_key": "test_value",
|
||||
"sample_data": "example"
|
||||
}
|
||||
@@ -1,14 +1,14 @@
|
||||
{
|
||||
"error_catchup": {
|
||||
"last_scan_timestamp": "2026-03-05T22:08:52.170487",
|
||||
"last_scan_timestamp": "2026-03-06T08:14:16.212679",
|
||||
"processed_hashes": [
|
||||
"68dd0ab6",
|
||||
"02d93909",
|
||||
"c7edc03b",
|
||||
"4095ef97",
|
||||
"69de737b",
|
||||
"ace01637",
|
||||
"541e0b9b",
|
||||
"4095ef97"
|
||||
"ace01637",
|
||||
"02d93909"
|
||||
],
|
||||
"max_hashes": 500,
|
||||
"max_lookback_hours": 24
|
||||
|
||||
Reference in New Issue
Block a user