contextforge-repo 0.4.2.post2__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.
- contextforge/__init__.py +37 -0
- contextforge/__main__.py +6 -0
- contextforge/_metadata.py +6 -0
- contextforge/api/__init__.py +5 -0
- contextforge/api/app.py +21 -0
- contextforge/api/routes.py +22 -0
- contextforge/application.py +1408 -0
- contextforge/benchmarks/__init__.py +55 -0
- contextforge/benchmarks/metrics.py +228 -0
- contextforge/benchmarks/models.py +490 -0
- contextforge/benchmarks/renderers.py +438 -0
- contextforge/benchmarks/runner.py +545 -0
- contextforge/cli/__init__.py +1 -0
- contextforge/cli/benchmark_commands.py +249 -0
- contextforge/cli/context_commands.py +702 -0
- contextforge/cli/diagnostics_commands.py +244 -0
- contextforge/cli/intelligence_commands.py +493 -0
- contextforge/cli/main.py +407 -0
- contextforge/cli/mcp_commands.py +77 -0
- contextforge/cli/progress.py +479 -0
- contextforge/cli/scan_output.py +189 -0
- contextforge/config.py +30 -0
- contextforge/context/__init__.py +171 -0
- contextforge/context/builder.py +244 -0
- contextforge/context/inspection.py +298 -0
- contextforge/context/package.py +386 -0
- contextforge/context/reader.py +427 -0
- contextforge/context/renderers.py +196 -0
- contextforge/context/selection.py +438 -0
- contextforge/context/tree.py +237 -0
- contextforge/core/__init__.py +30 -0
- contextforge/core/models.py +22 -0
- contextforge/core/validation.py +32 -0
- contextforge/diagnostics.py +496 -0
- contextforge/discovery/__init__.py +89 -0
- contextforge/discovery/completeness.py +289 -0
- contextforge/discovery/constraints.py +199 -0
- contextforge/discovery/models.py +466 -0
- contextforge/discovery/renderers.py +479 -0
- contextforge/discovery/session.py +3006 -0
- contextforge/discovery/tools.py +1332 -0
- contextforge/filesystem.py +253 -0
- contextforge/git/__init__.py +19 -0
- contextforge/git/diff.py +416 -0
- contextforge/handoff/__init__.py +72 -0
- contextforge/handoff/compiler.py +448 -0
- contextforge/handoff/flow.py +184 -0
- contextforge/handoff/materialize.py +771 -0
- contextforge/handoff/models.py +488 -0
- contextforge/handoff/refinement.py +104 -0
- contextforge/intelligence/__init__.py +303 -0
- contextforge/intelligence/codemap.py +532 -0
- contextforge/intelligence/extractors.py +57 -0
- contextforge/intelligence/fallback.py +55 -0
- contextforge/intelligence/indexer.py +336 -0
- contextforge/intelligence/manifest.py +266 -0
- contextforge/intelligence/map_models.py +583 -0
- contextforge/intelligence/maps.py +2292 -0
- contextforge/intelligence/models.py +331 -0
- contextforge/intelligence/python.py +1008 -0
- contextforge/intelligence/relationships.py +542 -0
- contextforge/intelligence/semantic_models.py +265 -0
- contextforge/intelligence/semantics.py +2401 -0
- contextforge/intelligence/store.py +1189 -0
- contextforge/logging.py +794 -0
- contextforge/mcp/__init__.py +18 -0
- contextforge/mcp/foundation.py +432 -0
- contextforge/mcp/server.py +227 -0
- contextforge/models/__init__.py +165 -0
- contextforge/models/fake.py +127 -0
- contextforge/models/ollama.py +496 -0
- contextforge/models/openai_compatible.py +924 -0
- contextforge/models/providers.py +3484 -0
- contextforge/progress.py +891 -0
- contextforge/project_config.py +729 -0
- contextforge/prompts/__init__.py +5 -0
- contextforge/prompts/package.py +12 -0
- contextforge/py.typed +1 -0
- contextforge/repositories/__init__.py +23 -0
- contextforge/repositories/analysis.py +12 -0
- contextforge/repositories/files.py +180 -0
- contextforge/repositories/ignore.py +259 -0
- contextforge/repositories/language.py +80 -0
- contextforge/repositories/models.py +123 -0
- contextforge/repositories/scanner.py +274 -0
- contextforge/storage/__init__.py +5 -0
- contextforge/storage/backend.py +11 -0
- contextforge_repo-0.4.2.post2.dist-info/METADATA +438 -0
- contextforge_repo-0.4.2.post2.dist-info/RECORD +93 -0
- contextforge_repo-0.4.2.post2.dist-info/WHEEL +4 -0
- contextforge_repo-0.4.2.post2.dist-info/entry_points.txt +3 -0
- contextforge_repo-0.4.2.post2.dist-info/licenses/LICENSE +202 -0
- contextforge_repo-0.4.2.post2.dist-info/licenses/NOTICE +4 -0
contextforge/__init__.py
ADDED
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
"""ContextForge package."""
|
|
2
|
+
|
|
3
|
+
from contextforge._metadata import __version__
|
|
4
|
+
from contextforge.logging import (
|
|
5
|
+
DIAGNOSTIC_SCHEMA_VERSION,
|
|
6
|
+
DiagnosticRecord,
|
|
7
|
+
LogFormat,
|
|
8
|
+
LogLevel,
|
|
9
|
+
recent_records,
|
|
10
|
+
)
|
|
11
|
+
from contextforge.progress import (
|
|
12
|
+
NO_OP_PROGRESS_OBSERVER,
|
|
13
|
+
PROGRESS_SCHEMA_VERSION,
|
|
14
|
+
NoOpProgressObserver,
|
|
15
|
+
ProgressActivity,
|
|
16
|
+
ProgressEvent,
|
|
17
|
+
ProgressObserver,
|
|
18
|
+
ProgressReporter,
|
|
19
|
+
ProgressStatus,
|
|
20
|
+
)
|
|
21
|
+
|
|
22
|
+
__all__ = [
|
|
23
|
+
"NO_OP_PROGRESS_OBSERVER",
|
|
24
|
+
"DIAGNOSTIC_SCHEMA_VERSION",
|
|
25
|
+
"DiagnosticRecord",
|
|
26
|
+
"LogFormat",
|
|
27
|
+
"LogLevel",
|
|
28
|
+
"PROGRESS_SCHEMA_VERSION",
|
|
29
|
+
"NoOpProgressObserver",
|
|
30
|
+
"ProgressActivity",
|
|
31
|
+
"ProgressEvent",
|
|
32
|
+
"ProgressObserver",
|
|
33
|
+
"ProgressReporter",
|
|
34
|
+
"ProgressStatus",
|
|
35
|
+
"recent_records",
|
|
36
|
+
"__version__",
|
|
37
|
+
]
|
contextforge/__main__.py
ADDED
contextforge/api/app.py
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"""FastAPI application factory."""
|
|
2
|
+
|
|
3
|
+
from fastapi import FastAPI
|
|
4
|
+
|
|
5
|
+
from contextforge._metadata import APP_NAME, APP_TAGLINE, __version__
|
|
6
|
+
from contextforge.api.routes import router
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
def create_app() -> FastAPI:
|
|
10
|
+
"""Create the local ContextForge API application."""
|
|
11
|
+
|
|
12
|
+
app = FastAPI(
|
|
13
|
+
title=APP_NAME,
|
|
14
|
+
description=APP_TAGLINE,
|
|
15
|
+
version=__version__,
|
|
16
|
+
)
|
|
17
|
+
app.include_router(router)
|
|
18
|
+
return app
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
app = create_app()
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
"""Minimal local API routes."""
|
|
2
|
+
|
|
3
|
+
from fastapi import APIRouter
|
|
4
|
+
|
|
5
|
+
from contextforge._metadata import APP_NAME, __version__
|
|
6
|
+
from contextforge.core import HealthStatus, VersionInfo
|
|
7
|
+
|
|
8
|
+
router = APIRouter()
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
@router.get("/health", response_model=HealthStatus)
|
|
12
|
+
def health() -> HealthStatus:
|
|
13
|
+
"""Return local API health status."""
|
|
14
|
+
|
|
15
|
+
return HealthStatus(status="ok")
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
@router.get("/version", response_model=VersionInfo)
|
|
19
|
+
def version() -> VersionInfo:
|
|
20
|
+
"""Return application version information."""
|
|
21
|
+
|
|
22
|
+
return VersionInfo(name=APP_NAME, version=__version__)
|