empathy-framework 4.7.0__py3-none-any.whl → 4.8.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- empathy_framework-4.8.0.dist-info/METADATA +753 -0
- {empathy_framework-4.7.0.dist-info → empathy_framework-4.8.0.dist-info}/RECORD +83 -37
- {empathy_framework-4.7.0.dist-info → empathy_framework-4.8.0.dist-info}/WHEEL +1 -1
- {empathy_framework-4.7.0.dist-info → empathy_framework-4.8.0.dist-info}/entry_points.txt +2 -1
- empathy_os/__init__.py +2 -0
- empathy_os/cache/hash_only.py +6 -3
- empathy_os/cache/hybrid.py +6 -3
- empathy_os/cli/__init__.py +128 -238
- empathy_os/cli/__main__.py +5 -33
- empathy_os/cli/commands/__init__.py +1 -8
- empathy_os/cli/commands/help.py +331 -0
- empathy_os/cli/commands/info.py +140 -0
- empathy_os/cli/commands/inspect.py +437 -0
- empathy_os/cli/commands/metrics.py +92 -0
- empathy_os/cli/commands/orchestrate.py +184 -0
- empathy_os/cli/commands/patterns.py +207 -0
- empathy_os/cli/commands/provider.py +93 -81
- empathy_os/cli/commands/setup.py +96 -0
- empathy_os/cli/commands/status.py +235 -0
- empathy_os/cli/commands/sync.py +166 -0
- empathy_os/cli/commands/tier.py +121 -0
- empathy_os/cli/commands/workflow.py +574 -0
- empathy_os/cli/parsers/__init__.py +62 -0
- empathy_os/cli/parsers/help.py +41 -0
- empathy_os/cli/parsers/info.py +26 -0
- empathy_os/cli/parsers/inspect.py +66 -0
- empathy_os/cli/parsers/metrics.py +42 -0
- empathy_os/cli/parsers/orchestrate.py +61 -0
- empathy_os/cli/parsers/patterns.py +54 -0
- empathy_os/cli/parsers/provider.py +40 -0
- empathy_os/cli/parsers/setup.py +42 -0
- empathy_os/cli/parsers/status.py +47 -0
- empathy_os/cli/parsers/sync.py +31 -0
- empathy_os/cli/parsers/tier.py +33 -0
- empathy_os/cli/parsers/workflow.py +77 -0
- empathy_os/cli/utils/__init__.py +1 -0
- empathy_os/cli/utils/data.py +242 -0
- empathy_os/cli/utils/helpers.py +68 -0
- empathy_os/{cli.py → cli_legacy.py} +27 -27
- empathy_os/cli_minimal.py +662 -0
- empathy_os/cli_router.py +384 -0
- empathy_os/cli_unified.py +38 -2
- empathy_os/memory/__init__.py +19 -5
- empathy_os/memory/short_term.py +14 -404
- empathy_os/memory/types.py +437 -0
- empathy_os/memory/unified.py +61 -48
- empathy_os/models/fallback.py +1 -1
- empathy_os/models/provider_config.py +59 -344
- empathy_os/models/registry.py +31 -180
- empathy_os/monitoring/alerts.py +14 -20
- empathy_os/monitoring/alerts_cli.py +24 -7
- empathy_os/project_index/__init__.py +2 -0
- empathy_os/project_index/index.py +210 -5
- empathy_os/project_index/scanner.py +45 -14
- empathy_os/project_index/scanner_parallel.py +291 -0
- empathy_os/socratic/ab_testing.py +1 -1
- empathy_os/vscode_bridge 2.py +173 -0
- empathy_os/workflows/__init__.py +31 -2
- empathy_os/workflows/base.py +349 -325
- empathy_os/workflows/bug_predict.py +8 -0
- empathy_os/workflows/builder.py +273 -0
- empathy_os/workflows/caching.py +253 -0
- empathy_os/workflows/code_review_pipeline.py +1 -0
- empathy_os/workflows/history.py +510 -0
- empathy_os/workflows/output.py +410 -0
- empathy_os/workflows/perf_audit.py +125 -19
- empathy_os/workflows/progress.py +324 -22
- empathy_os/workflows/progressive/README 2.md +454 -0
- empathy_os/workflows/progressive/__init__ 2.py +92 -0
- empathy_os/workflows/progressive/cli 2.py +242 -0
- empathy_os/workflows/progressive/core 2.py +488 -0
- empathy_os/workflows/progressive/orchestrator 2.py +701 -0
- empathy_os/workflows/progressive/reports 2.py +528 -0
- empathy_os/workflows/progressive/telemetry 2.py +280 -0
- empathy_os/workflows/progressive/test_gen 2.py +514 -0
- empathy_os/workflows/progressive/workflow 2.py +628 -0
- empathy_os/workflows/routing.py +168 -0
- empathy_os/workflows/secure_release.py +1 -0
- empathy_os/workflows/security_audit.py +190 -0
- empathy_os/workflows/security_audit_phase3.py +328 -0
- empathy_os/workflows/telemetry_mixin.py +269 -0
- empathy_framework-4.7.0.dist-info/METADATA +0 -1598
- empathy_os/dashboard/__init__.py +0 -15
- empathy_os/dashboard/server.py +0 -941
- {empathy_framework-4.7.0.dist-info → empathy_framework-4.8.0.dist-info}/licenses/LICENSE +0 -0
- {empathy_framework-4.7.0.dist-info → empathy_framework-4.8.0.dist-info}/top_level.txt +0 -0
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
"""Parser definitions for info commands.
|
|
2
|
+
|
|
3
|
+
Copyright 2025 Smart-AI-Memory
|
|
4
|
+
Licensed under Fair Source License 0.9
|
|
5
|
+
"""
|
|
6
|
+
|
|
7
|
+
from ..commands import info as info_commands
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
def register_parsers(subparsers):
|
|
11
|
+
"""Register info command parsers.
|
|
12
|
+
|
|
13
|
+
Args:
|
|
14
|
+
subparsers: ArgumentParser subparsers object
|
|
15
|
+
"""
|
|
16
|
+
# info command
|
|
17
|
+
parser_info = subparsers.add_parser("info", help="Display framework information")
|
|
18
|
+
parser_info.add_argument("--config", help="Path to config file")
|
|
19
|
+
parser_info.set_defaults(func=info_commands.cmd_info)
|
|
20
|
+
|
|
21
|
+
# frameworks command
|
|
22
|
+
parser_frameworks = subparsers.add_parser("frameworks", help="List agent frameworks")
|
|
23
|
+
parser_frameworks.add_argument("--all", action="store_true", help="Show all frameworks")
|
|
24
|
+
parser_frameworks.add_argument("--recommend", help="Recommend for use case")
|
|
25
|
+
parser_frameworks.add_argument("--json", action="store_true", help="Output as JSON")
|
|
26
|
+
parser_frameworks.set_defaults(func=info_commands.cmd_frameworks)
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
"""Parser definitions for inspect commands.
|
|
2
|
+
|
|
3
|
+
Copyright 2025 Smart-AI-Memory
|
|
4
|
+
Licensed under Fair Source License 0.9
|
|
5
|
+
"""
|
|
6
|
+
|
|
7
|
+
from ..commands import inspect
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
def register_parsers(subparsers):
|
|
11
|
+
"""Register inspect command parsers.
|
|
12
|
+
|
|
13
|
+
Args:
|
|
14
|
+
subparsers: ArgumentParser subparsers object from main parser
|
|
15
|
+
"""
|
|
16
|
+
# Run command - Interactive REPL
|
|
17
|
+
parser_run = subparsers.add_parser("run", help="Interactive REPL mode")
|
|
18
|
+
parser_run.add_argument("--config", "-c", help="Configuration file path")
|
|
19
|
+
parser_run.add_argument("--user-id", help="User ID (default: cli_user)")
|
|
20
|
+
parser_run.add_argument(
|
|
21
|
+
"--level",
|
|
22
|
+
type=int,
|
|
23
|
+
default=4,
|
|
24
|
+
help="Target empathy level (1-5, default: 4)",
|
|
25
|
+
)
|
|
26
|
+
parser_run.set_defaults(func=inspect.cmd_run)
|
|
27
|
+
|
|
28
|
+
# Inspect command - Unified inspection
|
|
29
|
+
parser_inspect = subparsers.add_parser("inspect", help="Inspect patterns, metrics, or state")
|
|
30
|
+
parser_inspect.add_argument(
|
|
31
|
+
"type",
|
|
32
|
+
choices=["patterns", "metrics", "state"],
|
|
33
|
+
help="Type of inspection (patterns, metrics, or state)",
|
|
34
|
+
)
|
|
35
|
+
parser_inspect.add_argument("--user-id", help="User ID to filter by (optional)")
|
|
36
|
+
parser_inspect.add_argument("--db", help="Database path (default: .empathy/patterns.db)")
|
|
37
|
+
parser_inspect.add_argument(
|
|
38
|
+
"--state-dir",
|
|
39
|
+
help="State directory path (default: .empathy/state)",
|
|
40
|
+
)
|
|
41
|
+
parser_inspect.set_defaults(func=inspect.cmd_inspect)
|
|
42
|
+
|
|
43
|
+
# Export command
|
|
44
|
+
parser_export = subparsers.add_parser(
|
|
45
|
+
"export",
|
|
46
|
+
help="Export patterns to file for sharing/backup",
|
|
47
|
+
)
|
|
48
|
+
parser_export.add_argument("output", help="Output file path")
|
|
49
|
+
parser_export.add_argument(
|
|
50
|
+
"--user-id",
|
|
51
|
+
help="User ID to export (optional, exports all if not specified)",
|
|
52
|
+
)
|
|
53
|
+
parser_export.add_argument("--db", help="Database path (default: .empathy/patterns.db)")
|
|
54
|
+
parser_export.add_argument(
|
|
55
|
+
"--format",
|
|
56
|
+
default="json",
|
|
57
|
+
choices=["json"],
|
|
58
|
+
help="Export format (default: json)",
|
|
59
|
+
)
|
|
60
|
+
parser_export.set_defaults(func=inspect.cmd_export)
|
|
61
|
+
|
|
62
|
+
# Import command
|
|
63
|
+
parser_import = subparsers.add_parser("import", help="Import patterns from file")
|
|
64
|
+
parser_import.add_argument("input", help="Input file path")
|
|
65
|
+
parser_import.add_argument("--db", help="Database path (default: .empathy/patterns.db)")
|
|
66
|
+
parser_import.set_defaults(func=inspect.cmd_import)
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
"""Parser definitions for metrics commands.
|
|
2
|
+
|
|
3
|
+
Copyright 2025 Smart-AI-Memory
|
|
4
|
+
Licensed under Fair Source License 0.9
|
|
5
|
+
"""
|
|
6
|
+
|
|
7
|
+
from ..commands import metrics
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
def register_parsers(subparsers):
|
|
11
|
+
"""Register metrics command parsers.
|
|
12
|
+
|
|
13
|
+
Args:
|
|
14
|
+
subparsers: ArgumentParser subparsers object from main parser
|
|
15
|
+
"""
|
|
16
|
+
# Metrics command
|
|
17
|
+
parser_metrics = subparsers.add_parser(
|
|
18
|
+
"metrics",
|
|
19
|
+
help="Display user metrics",
|
|
20
|
+
)
|
|
21
|
+
parser_metrics.add_argument(
|
|
22
|
+
"user",
|
|
23
|
+
help="User ID to retrieve metrics for",
|
|
24
|
+
)
|
|
25
|
+
parser_metrics.add_argument(
|
|
26
|
+
"--db",
|
|
27
|
+
default="./metrics.db",
|
|
28
|
+
help="Path to metrics database (default: ./metrics.db)",
|
|
29
|
+
)
|
|
30
|
+
parser_metrics.set_defaults(func=metrics.cmd_metrics_show)
|
|
31
|
+
|
|
32
|
+
# State command
|
|
33
|
+
parser_state = subparsers.add_parser(
|
|
34
|
+
"state",
|
|
35
|
+
help="List saved user states",
|
|
36
|
+
)
|
|
37
|
+
parser_state.add_argument(
|
|
38
|
+
"--state-dir",
|
|
39
|
+
default=".empathy/state",
|
|
40
|
+
help="State directory path (default: .empathy/state)",
|
|
41
|
+
)
|
|
42
|
+
parser_state.set_defaults(func=metrics.cmd_state_list)
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
"""Parser definitions for orchestrate commands.
|
|
2
|
+
|
|
3
|
+
Copyright 2025 Smart-AI-Memory
|
|
4
|
+
Licensed under Fair Source License 0.9
|
|
5
|
+
"""
|
|
6
|
+
|
|
7
|
+
from ..commands import orchestrate
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
def register_parsers(subparsers):
|
|
11
|
+
"""Register orchestrate command parsers.
|
|
12
|
+
|
|
13
|
+
Args:
|
|
14
|
+
subparsers: ArgumentParser subparsers object from main parser
|
|
15
|
+
"""
|
|
16
|
+
# Orchestrate command
|
|
17
|
+
parser_orchestrate = subparsers.add_parser(
|
|
18
|
+
"orchestrate",
|
|
19
|
+
help="Run meta-orchestration workflows (release-prep, health-check)",
|
|
20
|
+
)
|
|
21
|
+
parser_orchestrate.add_argument(
|
|
22
|
+
"workflow",
|
|
23
|
+
choices=["release-prep", "health-check", "test-coverage"],
|
|
24
|
+
help="Orchestration workflow to run",
|
|
25
|
+
)
|
|
26
|
+
parser_orchestrate.add_argument(
|
|
27
|
+
"--path",
|
|
28
|
+
default=".",
|
|
29
|
+
help="Project path (for release-prep)",
|
|
30
|
+
)
|
|
31
|
+
parser_orchestrate.add_argument(
|
|
32
|
+
"--mode",
|
|
33
|
+
choices=["daily", "weekly", "release"],
|
|
34
|
+
help="Health check mode (for health-check)",
|
|
35
|
+
)
|
|
36
|
+
parser_orchestrate.add_argument(
|
|
37
|
+
"--project-root",
|
|
38
|
+
default=".",
|
|
39
|
+
help="Project root directory (for health-check)",
|
|
40
|
+
)
|
|
41
|
+
parser_orchestrate.add_argument(
|
|
42
|
+
"--json",
|
|
43
|
+
action="store_true",
|
|
44
|
+
help="Output as JSON",
|
|
45
|
+
)
|
|
46
|
+
parser_orchestrate.add_argument(
|
|
47
|
+
"--min-coverage",
|
|
48
|
+
type=int,
|
|
49
|
+
help="Minimum test coverage percentage (for release-prep)",
|
|
50
|
+
)
|
|
51
|
+
parser_orchestrate.add_argument(
|
|
52
|
+
"--min-quality",
|
|
53
|
+
type=int,
|
|
54
|
+
help="Minimum quality score (for release-prep)",
|
|
55
|
+
)
|
|
56
|
+
parser_orchestrate.add_argument(
|
|
57
|
+
"--max-critical",
|
|
58
|
+
type=int,
|
|
59
|
+
help="Maximum critical issues allowed (for release-prep)",
|
|
60
|
+
)
|
|
61
|
+
parser_orchestrate.set_defaults(func=orchestrate.cmd_orchestrate)
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
"""Parser definitions for pattern commands.
|
|
2
|
+
|
|
3
|
+
Copyright 2025 Smart-AI-Memory
|
|
4
|
+
Licensed under Fair Source License 0.9
|
|
5
|
+
"""
|
|
6
|
+
|
|
7
|
+
from ..commands import patterns as patterns_commands
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
def register_parsers(subparsers):
|
|
11
|
+
"""Register pattern command parsers.
|
|
12
|
+
|
|
13
|
+
Args:
|
|
14
|
+
subparsers: ArgumentParser subparsers object
|
|
15
|
+
"""
|
|
16
|
+
# Create patterns subcommand group
|
|
17
|
+
patterns_parser = subparsers.add_parser("patterns", help="Pattern management commands")
|
|
18
|
+
patterns_subparsers = patterns_parser.add_subparsers(dest="patterns_command")
|
|
19
|
+
|
|
20
|
+
# patterns list
|
|
21
|
+
parser_list = patterns_subparsers.add_parser("list", help="List patterns in library")
|
|
22
|
+
parser_list.add_argument("library", help="Path to pattern library")
|
|
23
|
+
parser_list.add_argument(
|
|
24
|
+
"--format", choices=["json", "sqlite"], default="json", help="Library format"
|
|
25
|
+
)
|
|
26
|
+
parser_list.set_defaults(func=patterns_commands.cmd_patterns_list)
|
|
27
|
+
|
|
28
|
+
# patterns export
|
|
29
|
+
parser_export = patterns_subparsers.add_parser("export", help="Export patterns")
|
|
30
|
+
parser_export.add_argument("input", help="Input file path")
|
|
31
|
+
parser_export.add_argument("output", help="Output file path")
|
|
32
|
+
parser_export.add_argument(
|
|
33
|
+
"--input-format", choices=["json", "sqlite"], default="json", help="Input format"
|
|
34
|
+
)
|
|
35
|
+
parser_export.add_argument(
|
|
36
|
+
"--output-format", choices=["json", "sqlite"], default="json", help="Output format"
|
|
37
|
+
)
|
|
38
|
+
parser_export.set_defaults(func=patterns_commands.cmd_patterns_export)
|
|
39
|
+
|
|
40
|
+
# patterns resolve
|
|
41
|
+
parser_resolve = patterns_subparsers.add_parser("resolve", help="Resolve a bug pattern")
|
|
42
|
+
parser_resolve.add_argument("bug_id", nargs="?", help="Bug ID to resolve")
|
|
43
|
+
parser_resolve.add_argument("--root-cause", help="Root cause description")
|
|
44
|
+
parser_resolve.add_argument("--fix", help="Fix description")
|
|
45
|
+
parser_resolve.add_argument("--fix-code", help="Code snippet of the fix")
|
|
46
|
+
parser_resolve.add_argument("--time", type=int, help="Resolution time in minutes")
|
|
47
|
+
parser_resolve.add_argument(
|
|
48
|
+
"--patterns-dir", default="./patterns", help="Patterns directory path"
|
|
49
|
+
)
|
|
50
|
+
parser_resolve.add_argument("--resolved-by", help="Who resolved it")
|
|
51
|
+
parser_resolve.add_argument(
|
|
52
|
+
"--no-regenerate", action="store_true", help="Don't regenerate summary"
|
|
53
|
+
)
|
|
54
|
+
parser_resolve.set_defaults(func=patterns_commands.cmd_patterns_resolve)
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
"""Parser definitions for provider commands.
|
|
2
|
+
|
|
3
|
+
Copyright 2025 Smart-AI-Memory
|
|
4
|
+
Licensed under Fair Source License 0.9
|
|
5
|
+
"""
|
|
6
|
+
|
|
7
|
+
from ..commands import provider
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
def register_parsers(subparsers):
|
|
11
|
+
"""Register provider command parsers (Anthropic-only as of v5.0.0).
|
|
12
|
+
|
|
13
|
+
Args:
|
|
14
|
+
subparsers: ArgumentParser subparsers object from main parser
|
|
15
|
+
"""
|
|
16
|
+
# Provider parent command
|
|
17
|
+
parser_provider = subparsers.add_parser(
|
|
18
|
+
"provider",
|
|
19
|
+
help="Configure Claude/Anthropic provider",
|
|
20
|
+
)
|
|
21
|
+
provider_sub = parser_provider.add_subparsers(dest="provider_command", required=True)
|
|
22
|
+
|
|
23
|
+
# Provider show command
|
|
24
|
+
p_show = provider_sub.add_parser(
|
|
25
|
+
"show",
|
|
26
|
+
help="Show current provider configuration",
|
|
27
|
+
)
|
|
28
|
+
p_show.set_defaults(func=provider.cmd_provider_show)
|
|
29
|
+
|
|
30
|
+
# Provider set command
|
|
31
|
+
p_set = provider_sub.add_parser(
|
|
32
|
+
"set",
|
|
33
|
+
help="Set default provider (must be 'anthropic')",
|
|
34
|
+
)
|
|
35
|
+
p_set.add_argument(
|
|
36
|
+
"name",
|
|
37
|
+
choices=["anthropic"],
|
|
38
|
+
help="Provider name (anthropic only)",
|
|
39
|
+
)
|
|
40
|
+
p_set.set_defaults(func=provider.cmd_provider_set)
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
"""Parser definitions for setup commands.
|
|
2
|
+
|
|
3
|
+
Copyright 2025 Smart-AI-Memory
|
|
4
|
+
Licensed under Fair Source License 0.9
|
|
5
|
+
"""
|
|
6
|
+
|
|
7
|
+
from ..commands import setup
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
def register_parsers(subparsers):
|
|
11
|
+
"""Register setup command parsers.
|
|
12
|
+
|
|
13
|
+
Args:
|
|
14
|
+
subparsers: ArgumentParser subparsers object from main parser
|
|
15
|
+
"""
|
|
16
|
+
# Init command
|
|
17
|
+
parser_init = subparsers.add_parser(
|
|
18
|
+
"init",
|
|
19
|
+
help="Initialize a new Empathy Framework project",
|
|
20
|
+
)
|
|
21
|
+
parser_init.add_argument(
|
|
22
|
+
"--format",
|
|
23
|
+
choices=["yaml", "json"],
|
|
24
|
+
default="yaml",
|
|
25
|
+
help="Configuration format (default: yaml)",
|
|
26
|
+
)
|
|
27
|
+
parser_init.add_argument(
|
|
28
|
+
"--output",
|
|
29
|
+
help="Output file path (default: empathy.config.{format})",
|
|
30
|
+
)
|
|
31
|
+
parser_init.set_defaults(func=setup.cmd_init)
|
|
32
|
+
|
|
33
|
+
# Validate command
|
|
34
|
+
parser_validate = subparsers.add_parser(
|
|
35
|
+
"validate",
|
|
36
|
+
help="Validate a configuration file",
|
|
37
|
+
)
|
|
38
|
+
parser_validate.add_argument(
|
|
39
|
+
"config",
|
|
40
|
+
help="Path to configuration file to validate",
|
|
41
|
+
)
|
|
42
|
+
parser_validate.set_defaults(func=setup.cmd_validate)
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
"""Parser definitions for status and health commands.
|
|
2
|
+
|
|
3
|
+
Copyright 2025 Smart-AI-Memory
|
|
4
|
+
Licensed under Fair Source License 0.9
|
|
5
|
+
"""
|
|
6
|
+
|
|
7
|
+
from ..commands import status as status_commands
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
def register_parsers(subparsers):
|
|
11
|
+
"""Register status command parsers.
|
|
12
|
+
|
|
13
|
+
Args:
|
|
14
|
+
subparsers: ArgumentParser subparsers object
|
|
15
|
+
"""
|
|
16
|
+
# status command
|
|
17
|
+
parser_status = subparsers.add_parser("status", help="Show project status")
|
|
18
|
+
parser_status.add_argument("--patterns-dir", default="./patterns", help="Patterns directory")
|
|
19
|
+
parser_status.add_argument("--project-root", default=".", help="Project root")
|
|
20
|
+
parser_status.add_argument(
|
|
21
|
+
"--inactivity", type=int, default=30, help="Inactivity threshold (minutes)"
|
|
22
|
+
)
|
|
23
|
+
parser_status.add_argument("--full", action="store_true", help="Show all items")
|
|
24
|
+
parser_status.add_argument("--json", action="store_true", help="Output as JSON")
|
|
25
|
+
parser_status.add_argument("--select", type=int, help="Select item for action")
|
|
26
|
+
parser_status.add_argument("--force", action="store_true", help="Force show status")
|
|
27
|
+
parser_status.set_defaults(func=status_commands.cmd_status)
|
|
28
|
+
|
|
29
|
+
# review command (deprecated)
|
|
30
|
+
parser_review = subparsers.add_parser("review", help="Code review (deprecated)")
|
|
31
|
+
parser_review.set_defaults(func=status_commands.cmd_review)
|
|
32
|
+
|
|
33
|
+
# health command
|
|
34
|
+
parser_health = subparsers.add_parser("health", help="Run health checks")
|
|
35
|
+
parser_health.add_argument("--check", help="Specific check (lint/type/format/test)")
|
|
36
|
+
parser_health.add_argument("--deep", action="store_true", help="Run all checks")
|
|
37
|
+
parser_health.add_argument("--fix", action="store_true", help="Auto-fix issues")
|
|
38
|
+
parser_health.add_argument("--dry-run", action="store_true", help="Preview fixes only")
|
|
39
|
+
parser_health.add_argument(
|
|
40
|
+
"--interactive", action="store_true", help="Interactive fix mode"
|
|
41
|
+
)
|
|
42
|
+
parser_health.add_argument("--project-root", default=".", help="Project root")
|
|
43
|
+
parser_health.add_argument("--details", action="store_true", help="Show details")
|
|
44
|
+
parser_health.add_argument("--full", action="store_true", help="Show all details")
|
|
45
|
+
parser_health.add_argument("--trends", type=int, help="Show trends (days)")
|
|
46
|
+
parser_health.add_argument("--json", action="store_true", help="Output as JSON")
|
|
47
|
+
parser_health.set_defaults(func=status_commands.cmd_health)
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
"""Parser definitions for sync commands.
|
|
2
|
+
|
|
3
|
+
Copyright 2025 Smart-AI-Memory
|
|
4
|
+
Licensed under Fair Source License 0.9
|
|
5
|
+
"""
|
|
6
|
+
|
|
7
|
+
from ..commands import sync
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
def register_parsers(subparsers):
|
|
11
|
+
"""Register sync command parsers.
|
|
12
|
+
|
|
13
|
+
Args:
|
|
14
|
+
subparsers: ArgumentParser subparsers object from main parser
|
|
15
|
+
"""
|
|
16
|
+
# Sync-claude command
|
|
17
|
+
parser_sync_claude = subparsers.add_parser(
|
|
18
|
+
"sync-claude",
|
|
19
|
+
help="Sync learned patterns to Claude Code rules",
|
|
20
|
+
)
|
|
21
|
+
parser_sync_claude.add_argument(
|
|
22
|
+
"--patterns-dir",
|
|
23
|
+
default="patterns",
|
|
24
|
+
help="Source patterns directory (default: patterns)",
|
|
25
|
+
)
|
|
26
|
+
parser_sync_claude.add_argument(
|
|
27
|
+
"--output-dir",
|
|
28
|
+
default=".claude/rules/empathy",
|
|
29
|
+
help="Target Claude Code rules directory (default: .claude/rules/empathy)",
|
|
30
|
+
)
|
|
31
|
+
parser_sync_claude.set_defaults(func=sync.cmd_sync_claude)
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
"""Parser definitions for tier commands.
|
|
2
|
+
|
|
3
|
+
Copyright 2025 Smart-AI-Memory
|
|
4
|
+
Licensed under Fair Source License 0.9
|
|
5
|
+
"""
|
|
6
|
+
|
|
7
|
+
from ..commands import tier as tier_commands
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
def register_parsers(subparsers):
|
|
11
|
+
"""Register tier command parsers.
|
|
12
|
+
|
|
13
|
+
Args:
|
|
14
|
+
subparsers: ArgumentParser subparsers object
|
|
15
|
+
"""
|
|
16
|
+
# Create tier subcommand group
|
|
17
|
+
tier_parser = subparsers.add_parser("tier", help="Tier management commands")
|
|
18
|
+
tier_subparsers = tier_parser.add_subparsers(dest="tier_command")
|
|
19
|
+
|
|
20
|
+
# tier recommend
|
|
21
|
+
parser_recommend = tier_subparsers.add_parser(
|
|
22
|
+
"recommend", help="Get tier recommendation"
|
|
23
|
+
)
|
|
24
|
+
parser_recommend.add_argument("description", help="Bug or task description")
|
|
25
|
+
parser_recommend.add_argument("--files", help="Comma-separated list of files")
|
|
26
|
+
parser_recommend.add_argument(
|
|
27
|
+
"--complexity", choices=["low", "medium", "high"], help="Complexity hint"
|
|
28
|
+
)
|
|
29
|
+
parser_recommend.set_defaults(func=tier_commands.cmd_tier_recommend)
|
|
30
|
+
|
|
31
|
+
# tier stats
|
|
32
|
+
parser_stats = tier_subparsers.add_parser("stats", help="Show tier statistics")
|
|
33
|
+
parser_stats.set_defaults(func=tier_commands.cmd_tier_stats)
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
"""Parser definitions for workflow commands.
|
|
2
|
+
|
|
3
|
+
Copyright 2025 Smart-AI-Memory
|
|
4
|
+
Licensed under Fair Source License 0.9
|
|
5
|
+
"""
|
|
6
|
+
|
|
7
|
+
from ..commands import workflow
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
def register_parsers(subparsers):
|
|
11
|
+
"""Register workflow command parsers.
|
|
12
|
+
|
|
13
|
+
Args:
|
|
14
|
+
subparsers: ArgumentParser subparsers object from main parser
|
|
15
|
+
"""
|
|
16
|
+
# Main workflow command - multi-model workflow management
|
|
17
|
+
parser_workflow = subparsers.add_parser(
|
|
18
|
+
"workflow",
|
|
19
|
+
help="Multi-model workflows for cost-optimized task pipelines",
|
|
20
|
+
)
|
|
21
|
+
parser_workflow.add_argument(
|
|
22
|
+
"action",
|
|
23
|
+
choices=["list", "describe", "run", "config"],
|
|
24
|
+
help="Action: list, describe, run, or config",
|
|
25
|
+
)
|
|
26
|
+
parser_workflow.add_argument(
|
|
27
|
+
"name",
|
|
28
|
+
nargs="?",
|
|
29
|
+
help="Workflow name (for describe/run)",
|
|
30
|
+
)
|
|
31
|
+
parser_workflow.add_argument(
|
|
32
|
+
"--input",
|
|
33
|
+
"-i",
|
|
34
|
+
help="JSON input data for workflow execution",
|
|
35
|
+
)
|
|
36
|
+
parser_workflow.add_argument(
|
|
37
|
+
"--provider",
|
|
38
|
+
"-p",
|
|
39
|
+
choices=["anthropic", "openai", "google", "ollama", "hybrid"],
|
|
40
|
+
default=None, # None means use config
|
|
41
|
+
help="Model provider: anthropic, openai, google, ollama, or hybrid (mix of best models)",
|
|
42
|
+
)
|
|
43
|
+
parser_workflow.add_argument(
|
|
44
|
+
"--force",
|
|
45
|
+
action="store_true",
|
|
46
|
+
help="Force overwrite existing config file",
|
|
47
|
+
)
|
|
48
|
+
parser_workflow.add_argument("--json", action="store_true", help="Output as JSON")
|
|
49
|
+
parser_workflow.add_argument(
|
|
50
|
+
"--use-recommended-tier",
|
|
51
|
+
action="store_true",
|
|
52
|
+
help="Enable intelligent tier fallback: start with CHEAP tier and automatically upgrade if quality gates fail",
|
|
53
|
+
)
|
|
54
|
+
parser_workflow.add_argument(
|
|
55
|
+
"--write-tests",
|
|
56
|
+
action="store_true",
|
|
57
|
+
help="(test-gen workflow) Write generated tests to disk",
|
|
58
|
+
)
|
|
59
|
+
parser_workflow.add_argument(
|
|
60
|
+
"--output-dir",
|
|
61
|
+
default="tests/generated",
|
|
62
|
+
help="(test-gen workflow) Output directory for generated tests",
|
|
63
|
+
)
|
|
64
|
+
parser_workflow.add_argument(
|
|
65
|
+
"--health-score-threshold",
|
|
66
|
+
type=int,
|
|
67
|
+
default=95,
|
|
68
|
+
help="(health-check workflow) Minimum health score required (0-100, default: 95 for very strict quality)",
|
|
69
|
+
)
|
|
70
|
+
parser_workflow.set_defaults(func=workflow.cmd_workflow)
|
|
71
|
+
|
|
72
|
+
# Legacy workflow-setup command (DEPRECATED)
|
|
73
|
+
parser_workflow_setup = subparsers.add_parser(
|
|
74
|
+
"workflow-setup",
|
|
75
|
+
help="[DEPRECATED] Interactive setup wizard (use 'empathy init' instead)",
|
|
76
|
+
)
|
|
77
|
+
parser_workflow_setup.set_defaults(func=workflow.cmd_workflow_legacy)
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"""CLI utility functions."""
|