mirror of
https://github.com/syntrex-lab/gomcp.git
synced 2026-04-24 20:06:21 +02:00
chore: migrate module path to syntrex-lab and prepare open source release
This commit is contained in:
parent
a54c892736
commit
5cbb3d89d3
107 changed files with 465 additions and 594 deletions
176
LICENSE
Normal file
176
LICENSE
Normal file
|
|
@ -0,0 +1,176 @@
|
|||
Apache License
|
||||
Version 2.0, January 2004
|
||||
http://www.apache.org/licenses/
|
||||
|
||||
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
||||
|
||||
1. Definitions.
|
||||
|
||||
"License" shall mean the terms and conditions for use, reproduction,
|
||||
and distribution as defined by Sections 1 through 9 of this document.
|
||||
|
||||
"Licensor" shall mean the copyright owner or entity authorized by
|
||||
the copyright owner that is granting the License.
|
||||
|
||||
"Legal Entity" shall mean the union of the acting entity and all
|
||||
other entities that control, are controlled by, or are under common
|
||||
control with that entity. For the purposes of this definition,
|
||||
"control" means (i) the power, direct or indirect, to cause the
|
||||
direction or management of such entity, whether by contract or
|
||||
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
||||
outstanding shares, or (iii) beneficial ownership of such entity.
|
||||
|
||||
"You" (or "Your") shall mean an individual or Legal Entity
|
||||
exercising permissions granted by this License.
|
||||
|
||||
"Source" form shall mean the preferred form for making modifications,
|
||||
including but not limited to software source code, documentation
|
||||
source, and configuration files.
|
||||
|
||||
"Object" form shall mean any form resulting from mechanical
|
||||
transformation or translation of a Source form, including but
|
||||
not limited to compiled object code, generated documentation,
|
||||
and conversions to other media types.
|
||||
|
||||
"Work" shall mean the work of authorship, whether in Source or
|
||||
Object form, made available under the License, as indicated by a
|
||||
copyright notice that is included in or attached to the work
|
||||
(an example is provided in the Appendix below).
|
||||
|
||||
"Derivative Works" shall mean any work, whether in Source or Object
|
||||
form, that is based on (or derived from) the Work and for which the
|
||||
editorial revisions, annotations, elaborations, or other modifications
|
||||
represent, as a whole, an original work of authorship. For the purposes
|
||||
of this License, Derivative Works shall not include works that remain
|
||||
separable from, or merely link (or bind by name) to the interfaces of,
|
||||
the Work and Derivative Works thereof.
|
||||
|
||||
"Contribution" shall mean any work of authorship, including
|
||||
the original version of the Work and any modifications or additions
|
||||
to that Work or Derivative Works thereof, that is intentionally
|
||||
submitted to Licensor for inclusion in the Work by the copyright owner
|
||||
or by an individual or Legal Entity authorized to submit on behalf of
|
||||
the copyright owner. For the purposes of this definition, "submitted"
|
||||
means any form of electronic, verbal, or written communication sent
|
||||
to the Licensor or its representatives, including but not limited to
|
||||
communication on electronic mailing lists, source code control systems,
|
||||
and issue tracking systems that are managed by, or on behalf of, the
|
||||
Licensor for the purpose of discussing and improving the Work, but
|
||||
excluding communication that is conspicuously marked or otherwise
|
||||
designated in writing by the copyright owner as "Not a Contribution."
|
||||
|
||||
"Contributor" shall mean Licensor and any individual or Legal Entity
|
||||
on behalf of whom a Contribution has been received by Licensor and
|
||||
subsequently incorporated within the Work.
|
||||
|
||||
2. Grant of Copyright License. Subject to the terms and conditions of
|
||||
this License, each Contributor hereby grants to You a perpetual,
|
||||
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
||||
copyright license to reproduce, prepare Derivative Works of,
|
||||
publicly display, publicly perform, sublicense, and distribute the
|
||||
Work and such Derivative Works in Source or Object form.
|
||||
|
||||
3. Grant of Patent License. Subject to the terms and conditions of
|
||||
this License, each Contributor hereby grants to You a perpetual,
|
||||
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
||||
(except as stated in this section) patent license to make, have made,
|
||||
use, offer to sell, sell, import, and otherwise transfer the Work,
|
||||
where such license applies only to those patent claims licensable
|
||||
by such Contributor that are necessarily infringed by their
|
||||
Contribution(s) alone or by combination of their Contribution(s)
|
||||
with the Work to which such Contribution(s) was submitted. If You
|
||||
institute patent litigation against any entity (including a
|
||||
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
||||
or a Contribution incorporated within the Work constitutes direct
|
||||
or contributory patent infringement, then any patent licenses
|
||||
granted to You under this License for that Work shall terminate
|
||||
as of the date such litigation is filed.
|
||||
|
||||
4. Redistribution. You may reproduce and distribute copies of the
|
||||
Work or Derivative Works thereof in any medium, with or without
|
||||
modifications, and in Source or Object form, provided that You
|
||||
meet the following conditions:
|
||||
|
||||
(a) You must give any other recipients of the Work or
|
||||
Derivative Works a copy of this License; and
|
||||
|
||||
(b) You must cause any modified files to carry prominent notices
|
||||
stating that You changed the files; and
|
||||
|
||||
(c) You must retain, in the Source form of any Derivative Works
|
||||
that You distribute, all copyright, patent, trademark, and
|
||||
attribution notices from the Source form of the Work,
|
||||
excluding those notices that do not pertain to any part of
|
||||
the Derivative Works; and
|
||||
|
||||
(d) If the Work includes a "NOTICE" text file as part of its
|
||||
distribution, then any Derivative Works that You distribute must
|
||||
include a readable copy of the attribution notices contained
|
||||
within such NOTICE file, excluding those notices that do not
|
||||
pertain to any part of the Derivative Works, in at least one
|
||||
of the following places: within a NOTICE text file distributed
|
||||
as part of the Derivative Works; within the Source form or
|
||||
documentation, if provided along with the Derivative Works; or,
|
||||
within a display generated by the Derivative Works, if and
|
||||
wherever such third-party notices normally appear. The contents
|
||||
of the NOTICE file are for informational purposes only and
|
||||
do not modify the License. You may add Your own attribution
|
||||
notices within Derivative Works that You distribute, alongside
|
||||
or as an addendum to the NOTICE text from the Work, provided
|
||||
that such additional attribution notices cannot be construed
|
||||
as modifying the License.
|
||||
|
||||
You may add Your own copyright statement to Your modifications and
|
||||
may provide additional or different license terms and conditions
|
||||
for use, reproduction, or distribution of Your modifications, or
|
||||
for any such Derivative Works as a whole, provided Your use,
|
||||
reproduction, and distribution of the Work otherwise complies with
|
||||
the conditions stated in this License.
|
||||
|
||||
5. Submission of Contributions. Unless You explicitly state otherwise,
|
||||
any Contribution intentionally submitted for inclusion in the Work
|
||||
by You to the Licensor shall be under the terms and conditions of
|
||||
this License, without any additional terms or conditions.
|
||||
Notwithstanding the above, nothing herein shall supersede or modify
|
||||
the terms of any separate license agreement you may have executed
|
||||
with Licensor regarding such Contributions.
|
||||
|
||||
6. Trademarks. This License does not grant permission to use the trade
|
||||
names, trademarks, service marks, or product names of the Licensor,
|
||||
except as required for reasonable and customary use in describing the
|
||||
origin of the Work and reproducing the content of the NOTICE file.
|
||||
|
||||
7. Disclaimer of Warranty. Unless required by applicable law or
|
||||
agreed to in writing, Licensor provides the Work (and each
|
||||
Contributor provides its Contributions) on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
||||
implied, including, without limitation, any warranties or conditions
|
||||
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
||||
PARTICULAR PURPOSE. You are solely responsible for determining the
|
||||
appropriateness of using or redistributing the Work and assume any
|
||||
risks associated with Your exercise of permissions under this License.
|
||||
|
||||
8. Limitation of Liability. In no event and under no legal theory,
|
||||
whether in tort (including negligence), contract, or otherwise,
|
||||
unless required by applicable law (such as deliberate and grossly
|
||||
negligent acts) or agreed to in writing, shall any Contributor be
|
||||
liable to You for damages, including any direct, indirect, special,
|
||||
incidental, or consequential damages of any character arising as a
|
||||
result of this License or out of the use or inability to use the
|
||||
Work (including but not limited to damages for loss of goodwill,
|
||||
work stoppage, computer failure or malfunction, or any and all
|
||||
other commercial damages or losses), even if such Contributor
|
||||
has been advised of the possibility of such damages.
|
||||
|
||||
9. Accepting Warranty or Additional Liability. While redistributing
|
||||
the Work or Derivative Works thereof, You may choose to offer,
|
||||
and charge a fee for, acceptance of support, warranty, indemnity,
|
||||
or other liability obligations and/or rights consistent with this
|
||||
License. However, in accepting such obligations, You may act only
|
||||
on Your own behalf and on Your sole responsibility, not on behalf
|
||||
of any other Contributor, and only if You agree to indemnify,
|
||||
defend, and hold each Contributor harmless for any liability
|
||||
incurred by, or claims asserted against, such Contributor by reason
|
||||
of your accepting any such warranty or additional liability.
|
||||
|
||||
END OF TERMS AND CONDITIONS
|
||||
353
README.md
353
README.md
|
|
@ -1,343 +1,42 @@
|
|||
# GoMCP v2
|
||||
# GoMCP: Recursive Language Model Server
|
||||
|
||||
High-performance Go-native MCP server for the RLM Toolkit. Replaces the Python FastMCP server with a single static binary — no interpreter, no virtualenv, no startup lag.
|
||||

|
||||

|
||||

|
||||
|
||||
Part of the [Syntrex](https://github.com/syntrex/syntrex) AI security platform.
|
||||
> **The only Open-Source RLM (Recursive Language Model) Memory Server with Mathematically Proven Safety.**
|
||||
|
||||
## Features
|
||||
GoMCP is the enterprise core of the Syntrex AI SOC ecosystem. It is an extremely fast, secure, and persistent Model Context Protocol (MCP) server entirely written in Go. GoMCP gives Large Language Models a permanent, evolving memory and self-modifying context, transforming standard text agents into self-improving persistent intelligences.
|
||||
|
||||
- **Hierarchical Persistent Memory** — 4-level fact hierarchy (L0 Project → L1 Domain → L2 Module → L3 Snippet)
|
||||
- **Cognitive State Management** — save/restore/version session state vectors
|
||||
- **Causal Reasoning Chains** — directed graph of decisions, reasons, consequences
|
||||
- **Code Crystal Indexing** — structural index of codebase primitives
|
||||
- **Proactive Context Engine** — automatically injects relevant facts into every tool response
|
||||
- **Memory Loop** — tool calls are logged, summarized at shutdown, and restored at boot so the LLM never loses context
|
||||
- **Pure Go, Zero CGO** — uses `modernc.org/sqlite` and `bbolt` for storage
|
||||
- **Single Binary** — cross-compiles to Windows, Linux, macOS
|
||||
## 🚀 Key Features
|
||||
- **Context Consciousness Crystal (C³):** Hierarchical memory layers (L0-L3) combined with SQLite-backed temporal caching.
|
||||
- **57+ Native MCP Tools:** Deeply integrated tools for agentic self-reflection, codebase navigation, and file editing.
|
||||
- **Sub-millisecond latency:** Engineered for speed and durability under enterprise loads.
|
||||
- **Secure by Default:** Zero-G execution environment and robust isolation from the main operating system logic. DoH shielding, uTLS protocols, and session resumption natively integrated.
|
||||
|
||||
## Quick Start
|
||||
## ⚡ Quick Start
|
||||
|
||||
Install GoMCP as an independent memory server in 30 seconds:
|
||||
|
||||
```bash
|
||||
# Build
|
||||
make build
|
||||
|
||||
# Run (stdio transport, connects via MCP protocol)
|
||||
./gomcp -rlm-dir /path/to/.rlm
|
||||
|
||||
# Or on Windows
|
||||
gomcp.exe -rlm-dir C:\project\.rlm
|
||||
go install github.com/syntrex-lab/gomcp/cmd/gomcp@latest
|
||||
```
|
||||
|
||||
### OpenCode Integration
|
||||
|
||||
Add to `~/.config/opencode/opencode.json`:
|
||||
|
||||
```json
|
||||
{
|
||||
"mcpServers": {
|
||||
"gomcp": {
|
||||
"type": "stdio",
|
||||
"command": "C:/path/to/gomcp.exe",
|
||||
"args": ["-rlm-dir", "C:/project/.rlm"]
|
||||
}
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
## CLI Flags
|
||||
|
||||
| Flag | Default | Description |
|
||||
|------|---------|-------------|
|
||||
| `-rlm-dir` | `.rlm` | Path to `.rlm` data directory |
|
||||
| `-cache-path` | `<rlm-dir>/cache.db` | Path to bbolt hot cache file |
|
||||
| `-session` | `default` | Session ID for auto-restore |
|
||||
| `-python` | `python` | Path to Python interpreter (for NLP bridge) |
|
||||
| `-bridge-script` | _(empty)_ | Path to Python bridge script (enables NLP tools) |
|
||||
| `-no-context` | `false` | Disable Proactive Context Engine |
|
||||
|
||||
## Tools (40+ total)
|
||||
|
||||
### Memory (11 tools)
|
||||
|
||||
| Tool | Description |
|
||||
|------|-------------|
|
||||
| `add_fact` | Add a new hierarchical memory fact (L0–L3) |
|
||||
| `get_fact` | Retrieve a fact by ID |
|
||||
| `update_fact` | Update an existing fact's content or staleness |
|
||||
| `delete_fact` | Delete a fact by ID |
|
||||
| `list_facts` | List facts by domain or hierarchy level |
|
||||
| `search_facts` | Full-text search across all facts |
|
||||
| `list_domains` | List all unique fact domains |
|
||||
| `get_stale_facts` | Get stale facts for review |
|
||||
| `get_l0_facts` | Get all project-level (L0) facts |
|
||||
| `fact_stats` | Get fact store statistics |
|
||||
| `process_expired` | Process expired TTL facts |
|
||||
|
||||
### Session (7 tools)
|
||||
|
||||
| Tool | Description |
|
||||
|------|-------------|
|
||||
| `save_state` | Save cognitive state vector |
|
||||
| `load_state` | Load cognitive state (optionally a specific version) |
|
||||
| `list_sessions` | List all persisted sessions |
|
||||
| `delete_session` | Delete all versions of a session |
|
||||
| `restore_or_create` | Restore existing session or create new one |
|
||||
| `get_compact_state` | Get compact text summary for prompt injection |
|
||||
| `get_audit_log` | Get audit log for a session |
|
||||
|
||||
### Causal Reasoning (4 tools)
|
||||
|
||||
| Tool | Description |
|
||||
|------|-------------|
|
||||
| `add_causal_node` | Add a reasoning node (decision/reason/consequence/constraint/alternative/assumption) |
|
||||
| `add_causal_edge` | Add a causal edge (justifies/causes/constrains) |
|
||||
| `get_causal_chain` | Query causal chain for a decision |
|
||||
| `causal_stats` | Get causal store statistics |
|
||||
|
||||
### Code Crystals (4 tools)
|
||||
|
||||
| Tool | Description |
|
||||
|------|-------------|
|
||||
| `search_crystals` | Search code crystals by content |
|
||||
| `get_crystal` | Get a code crystal by file path |
|
||||
| `list_crystals` | List indexed code crystals with optional pattern filter |
|
||||
| `crystal_stats` | Get crystal index statistics |
|
||||
|
||||
### System (3 tools)
|
||||
|
||||
| Tool | Description |
|
||||
|------|-------------|
|
||||
| `health` | Server health status |
|
||||
| `version` | Server version, git commit, build date |
|
||||
| `dashboard` | Aggregate system dashboard with all metrics |
|
||||
|
||||
### Python Bridge (11 tools, optional)
|
||||
|
||||
Requires `-bridge-script` flag. Delegates to a Python subprocess for NLP operations.
|
||||
Uses `all-MiniLM-L6-v2` (sentence-transformers) for embeddings (384 dimensions).
|
||||
|
||||
| Tool | Description |
|
||||
|------|-------------|
|
||||
| `semantic_search` | Vector similarity search across facts |
|
||||
| `compute_embedding` | Compute embedding vector for text |
|
||||
| `reindex_embeddings` | Reindex all fact embeddings |
|
||||
| `consolidate_facts` | Consolidate duplicate/similar facts via NLP |
|
||||
| `enterprise_context` | Enterprise-level context summary |
|
||||
| `route_context` | Intent-based context routing |
|
||||
| `discover_deep` | Deep discovery of related facts and patterns |
|
||||
| `extract_from_conversation` | Extract facts from conversation text |
|
||||
| `index_embeddings` | Batch index embeddings for facts |
|
||||
| `build_communities` | Graph clustering of fact communities |
|
||||
| `check_python_bridge` | Check Python bridge availability |
|
||||
|
||||
#### Setting Up the Python Bridge
|
||||
Initialize your RLM context inside a workspace:
|
||||
|
||||
```bash
|
||||
# 1. Install Python dependencies
|
||||
pip install -r scripts/requirements-bridge.txt
|
||||
|
||||
# 2. Run GoMCP with the bridge
|
||||
./gomcp -rlm-dir /path/to/.rlm -bridge-script scripts/rlm_bridge.py
|
||||
|
||||
# 3. (Optional) Reindex embeddings for existing facts
|
||||
# Call via MCP: reindex_embeddings tool with force=true
|
||||
gomcp init
|
||||
gomcp serve --port 9100
|
||||
```
|
||||
|
||||
OpenCode config with bridge:
|
||||
## 🧠 Use Cases
|
||||
- **Autonomous Agents:** Build agents with infinite, structured memory.
|
||||
- **Secure RAG:** Query codebases with provable bounds and role-based clearance.
|
||||
- **Local AI Context:** Supercharge your local LLMs (Ollama, vLLM) with a centralized context nervous system.
|
||||
|
||||
```json
|
||||
{
|
||||
"mcpServers": {
|
||||
"gomcp": {
|
||||
"type": "stdio",
|
||||
"command": "C:/path/to/gomcp.exe",
|
||||
"args": [
|
||||
"-rlm-dir", "C:/project/.rlm",
|
||||
"-bridge-script", "C:/path/to/gomcp/scripts/rlm_bridge.py"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
**Protocol**: GoMCP spawns `python rlm_bridge.py` as a subprocess per call,
|
||||
sends `{"method": "...", "params": {...}}` on stdin, reads `{"result": ...}` from stdout.
|
||||
The bridge reads the same SQLite database as GoMCP (WAL mode, concurrent-safe).
|
||||
|
||||
**Environment**: Set `RLM_DIR` to override the `.rlm` directory path for the bridge.
|
||||
If unset, the bridge walks up from its script location looking for `.rlm/`.
|
||||
|
||||
## MCP Resources
|
||||
|
||||
| URI | Description |
|
||||
|-----|-------------|
|
||||
| `rlm://facts` | Project-level (L0) facts — always loaded |
|
||||
| `rlm://stats` | Aggregate memory store statistics |
|
||||
| `rlm://state/{session_id}` | Cognitive state vector for a session |
|
||||
|
||||
## Architecture
|
||||
|
||||
```
|
||||
cmd/gomcp/main.go Composition root, CLI, lifecycle
|
||||
internal/
|
||||
├── domain/ Pure domain types (no dependencies)
|
||||
│ ├── memory/ Fact, FactStore, HotCache interfaces
|
||||
│ ├── session/ CognitiveState, SessionStore
|
||||
│ ├── causal/ CausalNode, CausalEdge, CausalStore
|
||||
│ ├── crystal/ CodeCrystal, CrystalStore
|
||||
│ └── context/ EngineConfig, ScoredFact, ContextFrame
|
||||
├── infrastructure/ External adapters
|
||||
│ ├── sqlite/ SQLite repos (facts, sessions, causal, crystals, interaction log)
|
||||
│ ├── cache/ BoltDB hot cache for L0 facts
|
||||
│ └── pybridge/ Python subprocess bridge (JSON-RPC)
|
||||
├── application/ Use cases
|
||||
│ ├── tools/ Tool service layer (fact, session, causal, crystal, system)
|
||||
│ ├── resources/ MCP resource provider
|
||||
│ ├── contextengine/ Proactive Context Engine + Interaction Processor
|
||||
│ ├── resilience/ SARL — Self-Monitoring, Self-Healing, Self-Preservation
|
||||
│ └── lifecycle/ Graceful shutdown manager
|
||||
└── transport/
|
||||
└── mcpserver/ MCP server setup, tool registration, middleware wiring
|
||||
```
|
||||
|
||||
### SARL (Autonomous Resilience)
|
||||
|
||||
```
|
||||
internal/application/resilience/
|
||||
├── metrics_collector.go # Ring buffer time-series, Z-score anomaly detection
|
||||
├── health_monitor.go # L1: Quorum validation, alert bus, threshold checks
|
||||
├── healing_engine.go # L2: FSM (6 states), cooldown, rollback
|
||||
├── healing_strategies.go # 5 built-in strategies (restart, config, DB, rules, network)
|
||||
├── preservation.go # L3: Emergency modes (SAFE→LOCKDOWN→APOPTOSIS)
|
||||
├── integrity.go # Binary SHA-256, config HMAC-SHA256, chain verify
|
||||
├── behavioral.go # L4: Go runtime profiling (goroutines, heap, GC)
|
||||
└── recovery_playbooks.go # L5: 3 playbooks (resurrection, consensus, crypto)
|
||||
|
||||
transport/http/
|
||||
└── resilience_handlers.go # 6 REST endpoints (/api/v1/resilience/*)
|
||||
```
|
||||
|
||||
**81 tests** across 5 test files. All PASS.
|
||||
|
||||
**Dependency rule**: arrows point inward only. Domain has no imports from other layers.
|
||||
|
||||
## Proactive Context Engine
|
||||
|
||||
Every tool call automatically gets relevant facts injected into its response. No explicit `search_facts` needed — the engine:
|
||||
|
||||
1. Extracts keywords from tool arguments
|
||||
2. Scores facts by recency, frequency, hierarchy level, and keyword match
|
||||
3. Selects top facts within a token budget
|
||||
4. Appends a `[MEMORY CONTEXT]` block to the tool response
|
||||
|
||||
### Configuration
|
||||
|
||||
Create `.rlm/context.json` (optional — defaults are used if missing):
|
||||
|
||||
```json
|
||||
{
|
||||
"enabled": true,
|
||||
"token_budget": 300,
|
||||
"max_facts": 10,
|
||||
"recency_weight": 0.25,
|
||||
"frequency_weight": 0.15,
|
||||
"level_weight": 0.30,
|
||||
"keyword_weight": 0.30,
|
||||
"decay_half_life_hours": 72.0,
|
||||
"skip_tools": [
|
||||
"search_facts", "get_fact", "list_facts", "get_l0_facts",
|
||||
"get_stale_facts", "fact_stats", "list_domains", "process_expired",
|
||||
"semantic_search", "health", "version", "dashboard"
|
||||
]
|
||||
}
|
||||
```
|
||||
|
||||
## Memory Loop
|
||||
|
||||
The memory loop ensures context survives across sessions without manual intervention:
|
||||
|
||||
```
|
||||
Tool call → middleware logs to interaction_log (WAL, crash-safe)
|
||||
↓
|
||||
ProcessShutdown() at graceful exit
|
||||
→ summarizes tool calls, duration, topics → session-history fact
|
||||
→ marks entries processed
|
||||
↓
|
||||
Next session boot: ProcessStartup()
|
||||
→ processes unprocessed entries (crash recovery)
|
||||
→ OR retrieves last clean-shutdown summary
|
||||
↓
|
||||
Boot instructions = [AGENT INSTRUCTIONS] + [LAST SESSION] + [PROJECT FACTS]
|
||||
→ returned in MCP initialize response
|
||||
↓
|
||||
LLM starts with full context from day one
|
||||
```
|
||||
|
||||
## Data Directory Layout
|
||||
|
||||
```
|
||||
.rlm/
|
||||
├── memory/
|
||||
│ ├── memory_bridge_v2.db # Facts + interaction log (SQLite, WAL mode)
|
||||
│ ├── memory_bridge.db # Session states (SQLite)
|
||||
│ └── causal_chains.db # Causal graph (SQLite)
|
||||
├── crystals.db # Code crystal index (SQLite)
|
||||
├── cache.db # BoltDB hot cache (L0 facts)
|
||||
├── context.json # Context engine config (optional)
|
||||
└── .encryption_key # Encryption key (if used)
|
||||
```
|
||||
|
||||
Compatible with existing RLM Python databases (schema v2.0.0).
|
||||
|
||||
## Development
|
||||
|
||||
```bash
|
||||
# Prerequisites
|
||||
# Go 1.25+
|
||||
|
||||
# Run all tests
|
||||
make test
|
||||
|
||||
# Run tests with race detector
|
||||
make test-race
|
||||
|
||||
# Coverage report
|
||||
make cover-html
|
||||
|
||||
# Lint
|
||||
make lint
|
||||
|
||||
# Quality gate (lint + test + build)
|
||||
make check
|
||||
|
||||
# Cross-compile all platforms
|
||||
make cross
|
||||
|
||||
# Clean
|
||||
make clean
|
||||
```
|
||||
|
||||
### Key Dependencies
|
||||
|
||||
| Package | Version | Purpose |
|
||||
|---------|---------|---------|
|
||||
| [mcp-go](https://github.com/mark3labs/mcp-go) | v0.44.0 | MCP protocol framework |
|
||||
| [modernc.org/sqlite](https://pkg.go.dev/modernc.org/sqlite) | v1.46.0 | Pure Go SQLite (no CGO) |
|
||||
| [bbolt](https://pkg.go.dev/go.etcd.io/bbolt) | v1.4.3 | Embedded key-value store |
|
||||
| [testify](https://github.com/stretchr/testify) | v1.10.0 | Test assertions |
|
||||
|
||||
### Build with Version Info
|
||||
|
||||
```bash
|
||||
go build -ldflags "-X tools.GitCommit=$(git rev-parse --short HEAD) \
|
||||
-X tools.BuildDate=$(date -u +%Y-%m-%dT%H:%M:%SZ)" \
|
||||
-o gomcp ./cmd/gomcp/
|
||||
```
|
||||
|
||||
## Transport
|
||||
|
||||
GoMCP uses **stdio transport** with **line-delimited JSON** (one JSON object per line + `\n`). This is the mcp-go v0.44.0 default — NOT Content-Length framing.
|
||||
## 🛡️ Enterprise CTA
|
||||
Need a full SOC dashboard, 66 offensive Rust engines, and distributed intelligence orchestration?
|
||||
Check out our enterprise platform: **[Syntrex AI SOC](https://syntrex.pro)**
|
||||
|
||||
## License
|
||||
|
||||
Part of the Syntrex project. Apache 2.0 License.
|
||||
Licensed under Apache 2.0 – Free for commercial and private use.
|
||||
|
|
|
|||
|
|
@ -24,27 +24,27 @@ import (
|
|||
|
||||
"github.com/mark3labs/mcp-go/server"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/application/contextengine"
|
||||
"github.com/syntrex/gomcp/internal/application/lifecycle"
|
||||
"github.com/syntrex/gomcp/internal/application/orchestrator"
|
||||
"github.com/syntrex/gomcp/internal/application/resources"
|
||||
appsoc "github.com/syntrex/gomcp/internal/application/soc"
|
||||
"github.com/syntrex/gomcp/internal/application/tools"
|
||||
"github.com/syntrex/gomcp/internal/domain/alert"
|
||||
ctxdomain "github.com/syntrex/gomcp/internal/domain/context"
|
||||
"github.com/syntrex/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex/gomcp/internal/domain/oracle"
|
||||
"github.com/syntrex/gomcp/internal/domain/peer"
|
||||
domsoc "github.com/syntrex/gomcp/internal/domain/soc"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/audit"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/cache"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/hardware"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/ipc"
|
||||
onnxpkg "github.com/syntrex/gomcp/internal/infrastructure/onnx"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/sqlite"
|
||||
httpserver "github.com/syntrex/gomcp/internal/transport/http"
|
||||
mcpserver "github.com/syntrex/gomcp/internal/transport/mcpserver"
|
||||
"github.com/syntrex/gomcp/internal/transport/tui"
|
||||
"github.com/syntrex-lab/gomcp/internal/application/contextengine"
|
||||
"github.com/syntrex-lab/gomcp/internal/application/lifecycle"
|
||||
"github.com/syntrex-lab/gomcp/internal/application/orchestrator"
|
||||
"github.com/syntrex-lab/gomcp/internal/application/resources"
|
||||
appsoc "github.com/syntrex-lab/gomcp/internal/application/soc"
|
||||
"github.com/syntrex-lab/gomcp/internal/application/tools"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/alert"
|
||||
ctxdomain "github.com/syntrex-lab/gomcp/internal/domain/context"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/oracle"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/peer"
|
||||
domsoc "github.com/syntrex-lab/gomcp/internal/domain/soc"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/audit"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/cache"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/hardware"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/ipc"
|
||||
onnxpkg "github.com/syntrex-lab/gomcp/internal/infrastructure/onnx"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/sqlite"
|
||||
httpserver "github.com/syntrex-lab/gomcp/internal/transport/http"
|
||||
mcpserver "github.com/syntrex-lab/gomcp/internal/transport/mcpserver"
|
||||
"github.com/syntrex-lab/gomcp/internal/transport/tui"
|
||||
)
|
||||
|
||||
func main() {
|
||||
|
|
|
|||
|
|
@ -26,8 +26,8 @@ import (
|
|||
"syscall"
|
||||
"time"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/guard"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/logging"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/guard"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/logging"
|
||||
)
|
||||
|
||||
func main() {
|
||||
|
|
|
|||
|
|
@ -25,7 +25,7 @@ import (
|
|||
"syscall"
|
||||
"time"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/application/sidecar"
|
||||
"github.com/syntrex-lab/gomcp/internal/application/sidecar"
|
||||
)
|
||||
|
||||
func main() {
|
||||
|
|
|
|||
|
|
@ -24,12 +24,12 @@ import (
|
|||
"runtime/debug"
|
||||
"syscall"
|
||||
|
||||
appsoc "github.com/syntrex/gomcp/internal/application/soc"
|
||||
domsoc "github.com/syntrex/gomcp/internal/domain/soc"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/audit"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/ipc"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/logging"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/sqlite"
|
||||
appsoc "github.com/syntrex-lab/gomcp/internal/application/soc"
|
||||
domsoc "github.com/syntrex-lab/gomcp/internal/domain/soc"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/audit"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/ipc"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/logging"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/sqlite"
|
||||
)
|
||||
|
||||
func main() {
|
||||
|
|
|
|||
|
|
@ -21,12 +21,12 @@ import (
|
|||
"strconv"
|
||||
"syscall"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/application/soc"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/audit"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/ipc"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/logging"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/sqlite"
|
||||
sochttp "github.com/syntrex/gomcp/internal/transport/http"
|
||||
"github.com/syntrex-lab/gomcp/internal/application/soc"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/audit"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/ipc"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/logging"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/sqlite"
|
||||
sochttp "github.com/syntrex-lab/gomcp/internal/transport/http"
|
||||
)
|
||||
|
||||
func main() {
|
||||
|
|
|
|||
|
|
@ -23,9 +23,9 @@ import (
|
|||
"runtime/debug"
|
||||
"syscall"
|
||||
|
||||
domsoc "github.com/syntrex/gomcp/internal/domain/soc"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/ipc"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/logging"
|
||||
domsoc "github.com/syntrex-lab/gomcp/internal/domain/soc"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/ipc"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/logging"
|
||||
)
|
||||
|
||||
func main() {
|
||||
|
|
|
|||
|
|
@ -28,17 +28,17 @@ import (
|
|||
"strings"
|
||||
"syscall"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/application/soc"
|
||||
socdomain "github.com/syntrex/gomcp/internal/domain/soc"
|
||||
"github.com/syntrex/gomcp/internal/domain/engines"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/auth"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/audit"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/email"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/logging"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/postgres"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/sqlite"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/tracing"
|
||||
sochttp "github.com/syntrex/gomcp/internal/transport/http"
|
||||
"github.com/syntrex-lab/gomcp/internal/application/soc"
|
||||
socdomain "github.com/syntrex-lab/gomcp/internal/domain/soc"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/engines"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/auth"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/audit"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/email"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/logging"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/postgres"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/sqlite"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/tracing"
|
||||
sochttp "github.com/syntrex-lab/gomcp/internal/transport/http"
|
||||
)
|
||||
|
||||
func main() {
|
||||
|
|
|
|||
18
go.mod
18
go.mod
|
|
@ -1,14 +1,22 @@
|
|||
module github.com/syntrex/gomcp
|
||||
module github.com/syntrex-lab/gomcp
|
||||
|
||||
go 1.25.0
|
||||
|
||||
require (
|
||||
github.com/charmbracelet/bubbletea v1.3.10
|
||||
github.com/charmbracelet/lipgloss v1.1.0
|
||||
github.com/jackc/pgx/v5 v5.8.0
|
||||
github.com/mark3labs/mcp-go v0.44.0
|
||||
github.com/pressly/goose/v3 v3.27.0
|
||||
github.com/stretchr/testify v1.11.1
|
||||
github.com/swaggo/swag v1.16.6
|
||||
github.com/yalue/onnxruntime_go v1.27.0
|
||||
go.etcd.io/bbolt v1.4.3
|
||||
go.opentelemetry.io/otel v1.42.0
|
||||
go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.42.0
|
||||
go.opentelemetry.io/otel/sdk v1.42.0
|
||||
go.opentelemetry.io/otel/trace v1.42.0
|
||||
golang.org/x/crypto v0.49.0
|
||||
gopkg.in/yaml.v3 v3.0.1
|
||||
modernc.org/sqlite v1.46.1
|
||||
)
|
||||
|
|
@ -40,7 +48,6 @@ require (
|
|||
github.com/invopop/jsonschema v0.13.0 // indirect
|
||||
github.com/jackc/pgpassfile v1.0.0 // indirect
|
||||
github.com/jackc/pgservicefile v0.0.0-20240606120523-5a60cdf6a761 // indirect
|
||||
github.com/jackc/pgx/v5 v5.8.0 // indirect
|
||||
github.com/jackc/puddle/v2 v2.2.2 // indirect
|
||||
github.com/josharian/intern v1.0.0 // indirect
|
||||
github.com/lucasb-eyer/go-colorful v1.2.0 // indirect
|
||||
|
|
@ -54,25 +61,18 @@ require (
|
|||
github.com/muesli/termenv v0.16.0 // indirect
|
||||
github.com/ncruces/go-strftime v1.0.0 // indirect
|
||||
github.com/pmezard/go-difflib v1.0.0 // indirect
|
||||
github.com/pressly/goose/v3 v3.27.0 // indirect
|
||||
github.com/remyoudompheng/bigfft v0.0.0-20230129092748-24d4a6f8daec // indirect
|
||||
github.com/rivo/uniseg v0.4.7 // indirect
|
||||
github.com/sethvargo/go-retry v0.3.0 // indirect
|
||||
github.com/spf13/cast v1.7.1 // indirect
|
||||
github.com/swaggo/swag v1.16.6 // indirect
|
||||
github.com/wk8/go-ordered-map/v2 v2.1.8 // indirect
|
||||
github.com/xo/terminfo v0.0.0-20220910002029-abceb7e1c41e // indirect
|
||||
github.com/yosida95/uritemplate/v3 v3.0.2 // indirect
|
||||
go.opentelemetry.io/auto/sdk v1.2.1 // indirect
|
||||
go.opentelemetry.io/otel v1.42.0 // indirect
|
||||
go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.42.0 // indirect
|
||||
go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.42.0 // indirect
|
||||
go.opentelemetry.io/otel/metric v1.42.0 // indirect
|
||||
go.opentelemetry.io/otel/sdk v1.42.0 // indirect
|
||||
go.opentelemetry.io/otel/trace v1.42.0 // indirect
|
||||
go.opentelemetry.io/proto/otlp v1.9.0 // indirect
|
||||
go.uber.org/multierr v1.11.0 // indirect
|
||||
golang.org/x/crypto v0.49.0 // indirect
|
||||
golang.org/x/exp v0.0.0-20260218203240-3dfff04db8fa // indirect
|
||||
golang.org/x/mod v0.33.0 // indirect
|
||||
golang.org/x/net v0.51.0 // indirect
|
||||
|
|
|
|||
53
go.sum
53
go.sum
|
|
@ -51,8 +51,10 @@ github.com/go-openapi/spec v0.20.4/go.mod h1:faYFR1CvsJZ0mNsmsphTMSoRrNV3TEDoAM7
|
|||
github.com/go-openapi/swag v0.19.5/go.mod h1:POnQmlKehdgb5mhVOsnJFsivZCEZ/vjK9gh66Z9tfKk=
|
||||
github.com/go-openapi/swag v0.19.15 h1:D2NRCBzS9/pEY3gP9Nl8aDqGUcPFrwG2p+CNFrLyrCM=
|
||||
github.com/go-openapi/swag v0.19.15/go.mod h1:QYRuS/SOXUCsnplDa677K7+DxSOj6IPNl/eQntq43wQ=
|
||||
github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI=
|
||||
github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY=
|
||||
github.com/golang/protobuf v1.5.4 h1:i7eJL8qZTpSEXOPTxNKhASYpMn+8e5Q6AdndVa1dWek=
|
||||
github.com/golang/protobuf v1.5.4/go.mod h1:lnTiLA8Wa4RWRcIUkrtSVa5nRhsEGBg48fD6rSs7xps=
|
||||
github.com/google/go-cmp v0.7.0 h1:wk8382ETsv4JYUZwIsn6YpYiWiBsYLSJiTsyBybVuN8=
|
||||
github.com/google/go-cmp v0.7.0/go.mod h1:pXiqmnSA92OHEEa9HXL2W4E7lf9JzCmGVUdgjX3N/iU=
|
||||
github.com/google/pprof v0.0.0-20250317173921-a4b03ec1a45e h1:ijClszYn+mADRFY17kjQEVQ1XRhq2/JR1M3sGqeJoxs=
|
||||
github.com/google/pprof v0.0.0-20250317173921-a4b03ec1a45e/go.mod h1:boTsfXsheKC2y+lKOCMpSfarhxDeIzfZG1jqGcPl3cA=
|
||||
github.com/google/uuid v1.6.0 h1:NIvaJDMOsjHA8n1jAhLSgzrAzy1Hgr+hNrb57e+94F0=
|
||||
|
|
@ -115,8 +117,8 @@ github.com/remyoudompheng/bigfft v0.0.0-20230129092748-24d4a6f8daec/go.mod h1:qq
|
|||
github.com/rivo/uniseg v0.2.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJtxc=
|
||||
github.com/rivo/uniseg v0.4.7 h1:WUdvkW8uEhrYfLC4ZzdpI2ztxP1I582+49Oc5Mq64VQ=
|
||||
github.com/rivo/uniseg v0.4.7/go.mod h1:FN3SvrM+Zdj16jyLfmOkMNblXMcoc8DfTHruCPUcx88=
|
||||
github.com/rogpeppe/go-internal v1.9.0 h1:73kH8U+JUqXU8lRuOHeVHaa/SZPifC7BkcraZVejAe8=
|
||||
github.com/rogpeppe/go-internal v1.9.0/go.mod h1:WtVeX8xhTBvf0smdhujwtBcq4Qrzq/fJaraNFVN+nFs=
|
||||
github.com/rogpeppe/go-internal v1.14.1 h1:UQB4HGPB6osV0SQTLymcB4TgvyWu6ZyliaW0tI/otEQ=
|
||||
github.com/rogpeppe/go-internal v1.14.1/go.mod h1:MaRKkUm5W0goXpeCfT7UZI6fk/L7L7so1lCWt35ZSgc=
|
||||
github.com/sethvargo/go-retry v0.3.0 h1:EEt31A35QhrcRZtrYFDTBg91cqZVnFL2navjDrah2SE=
|
||||
github.com/sethvargo/go-retry v0.3.0/go.mod h1:mNX17F0C/HguQMyMyJxcnU471gOZGxCLyYaFyAZraas=
|
||||
github.com/spf13/cast v1.7.1 h1:cuNEagBQEHWN1FnbGEjCXL2szYEXqfJPbP2HNUaca9Y=
|
||||
|
|
@ -125,8 +127,6 @@ github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+
|
|||
github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI=
|
||||
github.com/stretchr/testify v1.6.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
|
||||
github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
|
||||
github.com/stretchr/testify v1.10.0 h1:Xv5erBjTwe/5IxqUQTdXv5kgmIvbHo3QQyRwhJsOfJA=
|
||||
github.com/stretchr/testify v1.10.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY=
|
||||
github.com/stretchr/testify v1.11.1 h1:7s2iGBzp5EwR7/aIZr8ao5+dra3wiQyKjjFuvgVKu7U=
|
||||
github.com/stretchr/testify v1.11.1/go.mod h1:wZwfW3scLgRK+23gO65QZefKpKQRnfz6sD981Nm4B6U=
|
||||
github.com/swaggo/swag v1.16.6 h1:qBNcx53ZaX+M5dxVyTrgQ0PJ/ACK+NzhwcbieTt+9yI=
|
||||
|
|
@ -153,71 +153,56 @@ go.opentelemetry.io/otel/metric v1.42.0 h1:2jXG+3oZLNXEPfNmnpxKDeZsFI5o4J+nz6xUl
|
|||
go.opentelemetry.io/otel/metric v1.42.0/go.mod h1:RlUN/7vTU7Ao/diDkEpQpnz3/92J9ko05BIwxYa2SSI=
|
||||
go.opentelemetry.io/otel/sdk v1.42.0 h1:LyC8+jqk6UJwdrI/8VydAq/hvkFKNHZVIWuslJXYsDo=
|
||||
go.opentelemetry.io/otel/sdk v1.42.0/go.mod h1:rGHCAxd9DAph0joO4W6OPwxjNTYWghRWmkHuGbayMts=
|
||||
go.opentelemetry.io/otel/sdk/metric v1.42.0 h1:D/1QR46Clz6ajyZ3G8SgNlTJKBdGp84q9RKCAZ3YGuA=
|
||||
go.opentelemetry.io/otel/sdk/metric v1.42.0/go.mod h1:Ua6AAlDKdZ7tdvaQKfSmnFTdHx37+J4ba8MwVCYM5hc=
|
||||
go.opentelemetry.io/otel/trace v1.42.0 h1:OUCgIPt+mzOnaUTpOQcBiM/PLQ/Op7oq6g4LenLmOYY=
|
||||
go.opentelemetry.io/otel/trace v1.42.0/go.mod h1:f3K9S+IFqnumBkKhRJMeaZeNk9epyhnCmQh/EysQCdc=
|
||||
go.opentelemetry.io/proto/otlp v1.9.0 h1:l706jCMITVouPOqEnii2fIAuO3IVGBRPV5ICjceRb/A=
|
||||
go.opentelemetry.io/proto/otlp v1.9.0/go.mod h1:xE+Cx5E/eEHw+ISFkwPLwCZefwVjY+pqKg1qcK03+/4=
|
||||
go.uber.org/goleak v1.3.0 h1:2K3zAYmnTNqV73imy9J1T3WC+gmCePx2hEGkimedGto=
|
||||
go.uber.org/goleak v1.3.0/go.mod h1:CoHD4mav9JJNrW/WLlf7HGZPjdw8EucARQHekz1X6bE=
|
||||
go.uber.org/multierr v1.11.0 h1:blXXJkSxSSfBVBlC76pxqeO+LN3aDfLQo+309xJstO0=
|
||||
go.uber.org/multierr v1.11.0/go.mod h1:20+QtiLqy0Nd6FdQB9TLXag12DsQkrbs3htMFfDN80Y=
|
||||
golang.org/x/crypto v0.49.0 h1:+Ng2ULVvLHnJ/ZFEq4KdcDd/cfjrrjjNSXNzxg0Y4U4=
|
||||
golang.org/x/crypto v0.49.0/go.mod h1:ErX4dUh2UM+CFYiXZRTcMpEcN8b/1gxEuv3nODoYtCA=
|
||||
golang.org/x/exp v0.0.0-20251023183803-a4bb9ffd2546 h1:mgKeJMpvi0yx/sU5GsxQ7p6s2wtOnGAHZWCHUM4KGzY=
|
||||
golang.org/x/exp v0.0.0-20251023183803-a4bb9ffd2546/go.mod h1:j/pmGrbnkbPtQfxEe5D0VQhZC6qKbfKifgD0oM7sR70=
|
||||
golang.org/x/exp v0.0.0-20260218203240-3dfff04db8fa h1:Zt3DZoOFFYkKhDT3v7Lm9FDMEV06GpzjG2jrqW+QTE0=
|
||||
golang.org/x/exp v0.0.0-20260218203240-3dfff04db8fa/go.mod h1:K79w1Vqn7PoiZn+TkNpx3BUWUQksGO3JcVX6qIjytmA=
|
||||
golang.org/x/mod v0.29.0 h1:HV8lRxZC4l2cr3Zq1LvtOsi/ThTgWnUk/y64QSs8GwA=
|
||||
golang.org/x/mod v0.29.0/go.mod h1:NyhrlYXJ2H4eJiRy/WDBO6HMqZQ6q9nk4JzS3NuCK+w=
|
||||
golang.org/x/mod v0.32.0 h1:9F4d3PHLljb6x//jOyokMv3eX+YDeepZSEo3mFJy93c=
|
||||
golang.org/x/mod v0.33.0 h1:tHFzIWbBifEmbwtGz65eaWyGiGZatSrT9prnU8DbVL8=
|
||||
golang.org/x/mod v0.33.0/go.mod h1:swjeQEj+6r7fODbD2cqrnje9PnziFuw4bmLbBZFrQ5w=
|
||||
golang.org/x/net v0.0.0-20210421230115-4e50805a0758/go.mod h1:72T/g9IO56b78aLF+1Kcs5dz7/ng1VjMUvfKvpfy+jM=
|
||||
golang.org/x/net v0.51.0 h1:94R/GTO7mt3/4wIKpcR5gkGmRLOuE/2hNGeWq/GBIFo=
|
||||
golang.org/x/net v0.51.0/go.mod h1:aamm+2QF5ogm02fjy5Bb7CQ0WMt1/WVM7FtyaTLlA9Y=
|
||||
golang.org/x/sync v0.17.0 h1:l60nONMj9l5drqw6jlhIELNv9I0A4OFgRsG9k2oT9Ug=
|
||||
golang.org/x/sync v0.17.0/go.mod h1:9KTHXmSnoGruLpwFjVSX0lNNA75CykiMECbovNTZqGI=
|
||||
golang.org/x/sync v0.19.0 h1:vV+1eWNmZ5geRlYjzm2adRgW2/mcpevXNg50YZtPCE4=
|
||||
golang.org/x/sync v0.19.0/go.mod h1:9KTHXmSnoGruLpwFjVSX0lNNA75CykiMECbovNTZqGI=
|
||||
golang.org/x/sync v0.20.0 h1:e0PTpb7pjO8GAtTs2dQ6jYa5BWYlMuX047Dco/pItO4=
|
||||
golang.org/x/sync v0.20.0/go.mod h1:9xrNwdLfx4jkKbNva9FpL6vEN7evnE43NNNJQ2LF3+0=
|
||||
golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20210420072515-93ed5bcd2bfe/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20210809222454-d867a43fc93e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.37.0 h1:fdNQudmxPjkdUTPnLn5mdQv7Zwvbvpaxqs831goi9kQ=
|
||||
golang.org/x/sys v0.37.0/go.mod h1:OgkHotnGiDImocRcuBABYBEXf8A9a87e/uXjp9XT3ks=
|
||||
golang.org/x/sys v0.41.0 h1:Ivj+2Cp/ylzLiEU89QhWblYnOE9zerudt9Ftecq2C6k=
|
||||
golang.org/x/sys v0.41.0/go.mod h1:OgkHotnGiDImocRcuBABYBEXf8A9a87e/uXjp9XT3ks=
|
||||
golang.org/x/sys v0.42.0 h1:omrd2nAlyT5ESRdCLYdm3+fMfNFE/+Rf4bDIQImRJeo=
|
||||
golang.org/x/sys v0.42.0/go.mod h1:4GL1E5IUh+htKOUEOaiffhrAeqysfVGipDYzABqnCmw=
|
||||
golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
|
||||
golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
|
||||
golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ=
|
||||
golang.org/x/text v0.3.8 h1:nAL+RVCQ9uMn3vJZbV+MRnydTJFPf8qqY42YiA6MrqY=
|
||||
golang.org/x/text v0.3.8/go.mod h1:E6s5w1FMmriuDzIBO73fBruAKo1PCIq6d2Q6DHfQ8WQ=
|
||||
golang.org/x/text v0.34.0 h1:oL/Qq0Kdaqxa1KbNeMKwQq0reLCCaFtqu2eNuSeNHbk=
|
||||
golang.org/x/text v0.34.0/go.mod h1:homfLqTYRFyVYemLBFl5GgL/DWEiH5wcsQ5gSh1yziA=
|
||||
golang.org/x/text v0.35.0 h1:JOVx6vVDFokkpaq1AEptVzLTpDe9KGpj5tR4/X+ybL8=
|
||||
golang.org/x/text v0.35.0/go.mod h1:khi/HExzZJ2pGnjenulevKNX1W67CUy0AsXcNubPGCA=
|
||||
golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.38.0 h1:Hx2Xv8hISq8Lm16jvBZ2VQf+RLmbd7wVUsALibYI/IQ=
|
||||
golang.org/x/tools v0.38.0/go.mod h1:yEsQ/d/YK8cjh0L6rZlY8tgtlKiBNTL14pGDJPJpYQs=
|
||||
golang.org/x/tools v0.41.0 h1:a9b8iMweWG+S0OBnlU36rzLp20z1Rp10w+IY2czHTQc=
|
||||
golang.org/x/tools v0.42.0 h1:uNgphsn75Tdz5Ji2q36v/nsFSfR/9BRFvqhGBaJGd5k=
|
||||
golang.org/x/tools v0.42.0/go.mod h1:Ma6lCIwGZvHK6XtgbswSoWroEkhugApmsXyrUmBhfr0=
|
||||
gonum.org/v1/gonum v0.16.0 h1:5+ul4Swaf3ESvrOnidPp4GZbzf0mxVQpDCYUQE7OJfk=
|
||||
gonum.org/v1/gonum v0.16.0/go.mod h1:fef3am4MQ93R2HHpKnLk4/Tbh/s0+wqD5nfa6Pnwy4E=
|
||||
google.golang.org/genproto/googleapis/api v0.0.0-20260209200024-4cfbd4190f57 h1:JLQynH/LBHfCTSbDWl+py8C+Rg/k1OVH3xfcaiANuF0=
|
||||
google.golang.org/genproto/googleapis/api v0.0.0-20260209200024-4cfbd4190f57/go.mod h1:kSJwQxqmFXeo79zOmbrALdflXQeAYcUbgS7PbpMknCY=
|
||||
google.golang.org/genproto/googleapis/rpc v0.0.0-20260209200024-4cfbd4190f57 h1:mWPCjDEyshlQYzBpMNHaEof6UX1PmHcaUODUywQ0uac=
|
||||
google.golang.org/genproto/googleapis/rpc v0.0.0-20260209200024-4cfbd4190f57/go.mod h1:j9x/tPzZkyxcgEFkiKEEGxfvyumM01BEtsW8xzOahRQ=
|
||||
google.golang.org/genproto/googleapis/rpc v0.0.0-20260217215200-42d3e9bedb6d h1:t/LOSXPJ9R0B6fnZNyALBRfZBH0Uy0gT+uR+SJ6syqQ=
|
||||
google.golang.org/genproto/googleapis/rpc v0.0.0-20260217215200-42d3e9bedb6d/go.mod h1:4Hqkh8ycfw05ld/3BWL7rJOSfebL2Q+DVDeRgYgxUU8=
|
||||
google.golang.org/grpc v1.79.2 h1:fRMD94s2tITpyJGtBBn7MkMseNpOZU8ZxgC3MMBaXRU=
|
||||
google.golang.org/grpc v1.79.2/go.mod h1:KmT0Kjez+0dde/v2j9vzwoAScgEPx/Bw1CYChhHLrHQ=
|
||||
google.golang.org/protobuf v1.36.11 h1:fV6ZwhNocDyBLK0dj+fg8ektcVegBBuEolpbTQyBNVE=
|
||||
google.golang.org/protobuf v1.36.11/go.mod h1:HTf+CrKn2C3g5S8VImy6tdcUvCska2kB7j23XfzDpco=
|
||||
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 h1:yhCVgyC4o1eVCa2tZl7eS0r+SDo693bJlVdllGtEeKM=
|
||||
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
|
||||
gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
|
||||
gopkg.in/check.v1 v1.0.0-20200227125254-8fa46927fb4f/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
|
||||
gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk=
|
||||
gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q=
|
||||
gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
|
||||
gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY=
|
||||
gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ=
|
||||
|
|
@ -227,20 +212,16 @@ gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA=
|
|||
gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
|
||||
modernc.org/cc/v4 v4.27.1 h1:9W30zRlYrefrDV2JE2O8VDtJ1yPGownxciz5rrbQZis=
|
||||
modernc.org/cc/v4 v4.27.1/go.mod h1:uVtb5OGqUKpoLWhqwNQo/8LwvoiEBLvZXIQ/SmO6mL0=
|
||||
modernc.org/ccgo/v4 v4.30.1 h1:4r4U1J6Fhj98NKfSjnPUN7Ze2c6MnAdL0hWw6+LrJpc=
|
||||
modernc.org/ccgo/v4 v4.30.1/go.mod h1:bIOeI1JL54Utlxn+LwrFyjCx2n2RDiYEaJVSrgdrRfM=
|
||||
modernc.org/ccgo/v4 v4.30.2 h1:4yPaaq9dXYXZ2V8s1UgrC3KIj580l2N4ClrLwnbv2so=
|
||||
modernc.org/ccgo/v4 v4.30.2/go.mod h1:yZMnhWEdW0qw3EtCndG1+ldRrVGS+bIwyWmAWzS0XEw=
|
||||
modernc.org/fileutil v1.3.40 h1:ZGMswMNc9JOCrcrakF1HrvmergNLAmxOPjizirpfqBA=
|
||||
modernc.org/fileutil v1.3.40/go.mod h1:HxmghZSZVAz/LXcMNwZPA/DRrQZEVP9VX0V4LQGQFOc=
|
||||
modernc.org/gc/v2 v2.6.5 h1:nyqdV8q46KvTpZlsw66kWqwXRHdjIlJOhG6kxiV/9xI=
|
||||
modernc.org/gc/v2 v2.6.5/go.mod h1:YgIahr1ypgfe7chRuJi2gD7DBQiKSLMPgBQe9oIiito=
|
||||
modernc.org/gc/v3 v3.1.1 h1:k8T3gkXWY9sEiytKhcgyiZ2L0DTyCQ/nvX+LoCljoRE=
|
||||
modernc.org/gc/v3 v3.1.1/go.mod h1:HFK/6AGESC7Ex+EZJhJ2Gni6cTaYpSMmU/cT9RmlfYY=
|
||||
modernc.org/gc/v3 v3.1.2 h1:ZtDCnhonXSZexk/AYsegNRV1lJGgaNZJuKjJSWKyEqo=
|
||||
modernc.org/gc/v3 v3.1.2/go.mod h1:HFK/6AGESC7Ex+EZJhJ2Gni6cTaYpSMmU/cT9RmlfYY=
|
||||
modernc.org/goabi0 v0.2.0 h1:HvEowk7LxcPd0eq6mVOAEMai46V+i7Jrj13t4AzuNks=
|
||||
modernc.org/goabi0 v0.2.0/go.mod h1:CEFRnnJhKvWT1c1JTI3Avm+tgOWbkOu5oPA8eH8LnMI=
|
||||
modernc.org/libc v1.67.6 h1:eVOQvpModVLKOdT+LvBPjdQqfrZq+pC39BygcT+E7OI=
|
||||
modernc.org/libc v1.67.6/go.mod h1:JAhxUVlolfYDErnwiqaLvUqc8nfb2r6S6slAgZOnaiE=
|
||||
modernc.org/libc v1.68.0 h1:PJ5ikFOV5pwpW+VqCK1hKJuEWsonkIJhhIXyuF/91pQ=
|
||||
modernc.org/libc v1.68.0/go.mod h1:NnKCYeoYgsEqnY3PgvNgAeaJnso968ygU8Z0DxjoEc0=
|
||||
modernc.org/mathutil v1.7.1 h1:GCZVGXdaN8gTqB1Mf/usp1Y/hSqgI2vAGGP4jZMCxOU=
|
||||
|
|
@ -251,8 +232,6 @@ modernc.org/opt v0.1.4 h1:2kNGMRiUjrp4LcaPuLY2PzUfqM/w9N23quVwhKt5Qm8=
|
|||
modernc.org/opt v0.1.4/go.mod h1:03fq9lsNfvkYSfxrfUhZCWPk1lm4cq4N+Bh//bEtgns=
|
||||
modernc.org/sortutil v1.2.1 h1:+xyoGf15mM3NMlPDnFqrteY07klSFxLElE2PVuWIJ7w=
|
||||
modernc.org/sortutil v1.2.1/go.mod h1:7ZI3a3REbai7gzCLcotuw9AC4VZVpYMjDzETGsSMqJE=
|
||||
modernc.org/sqlite v1.46.0 h1:pCVOLuhnT8Kwd0gjzPwqgQW1KW2XFpXyJB6cCw11jRE=
|
||||
modernc.org/sqlite v1.46.0/go.mod h1:CzbrU2lSB1DKUusvwGz7rqEKIq+NUd8GWuBBZDs9/nA=
|
||||
modernc.org/sqlite v1.46.1 h1:eFJ2ShBLIEnUWlLy12raN0Z1plqmFX9Qe3rjQTKt6sU=
|
||||
modernc.org/sqlite v1.46.1/go.mod h1:CzbrU2lSB1DKUusvwGz7rqEKIq+NUd8GWuBBZDs9/nA=
|
||||
modernc.org/strutil v1.2.1 h1:UneZBkQA+DX2Rp35KcM69cSsNES9ly8mQWD71HKlOA0=
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ import (
|
|||
"encoding/json"
|
||||
"os"
|
||||
|
||||
ctxdomain "github.com/syntrex/gomcp/internal/domain/context"
|
||||
ctxdomain "github.com/syntrex-lab/gomcp/internal/domain/context"
|
||||
)
|
||||
|
||||
// LoadConfig loads engine configuration from a JSON file.
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ import (
|
|||
"path/filepath"
|
||||
"testing"
|
||||
|
||||
ctxdomain "github.com/syntrex/gomcp/internal/domain/context"
|
||||
ctxdomain "github.com/syntrex-lab/gomcp/internal/domain/context"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ import (
|
|||
"github.com/mark3labs/mcp-go/mcp"
|
||||
"github.com/mark3labs/mcp-go/server"
|
||||
|
||||
ctxdomain "github.com/syntrex/gomcp/internal/domain/context"
|
||||
ctxdomain "github.com/syntrex-lab/gomcp/internal/domain/context"
|
||||
)
|
||||
|
||||
// InteractionLogger records tool calls for crash-safe memory.
|
||||
|
|
|
|||
|
|
@ -8,9 +8,9 @@ import (
|
|||
"time"
|
||||
|
||||
"github.com/mark3labs/mcp-go/mcp"
|
||||
"github.com/syntrex/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/memory"
|
||||
|
||||
ctxdomain "github.com/syntrex/gomcp/internal/domain/context"
|
||||
ctxdomain "github.com/syntrex-lab/gomcp/internal/domain/context"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
||||
|
|
|
|||
|
|
@ -10,8 +10,8 @@ import (
|
|||
"strings"
|
||||
"time"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/sqlite"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/sqlite"
|
||||
)
|
||||
|
||||
// InteractionProcessor processes unprocessed interaction log entries
|
||||
|
|
|
|||
|
|
@ -5,8 +5,8 @@ import (
|
|||
"testing"
|
||||
"time"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/sqlite"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/sqlite"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
||||
|
|
|
|||
|
|
@ -4,9 +4,9 @@ import (
|
|||
"context"
|
||||
"sync"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/memory"
|
||||
|
||||
ctxdomain "github.com/syntrex/gomcp/internal/domain/context"
|
||||
ctxdomain "github.com/syntrex-lab/gomcp/internal/domain/context"
|
||||
)
|
||||
|
||||
// StoreFactProvider adapts FactStore + HotCache to the FactProvider interface,
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@ import (
|
|||
"sync"
|
||||
"testing"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/memory"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
||||
|
|
|
|||
|
|
@ -18,11 +18,11 @@ import (
|
|||
"sync"
|
||||
"time"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/alert"
|
||||
"github.com/syntrex/gomcp/internal/domain/entropy"
|
||||
"github.com/syntrex/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex/gomcp/internal/domain/peer"
|
||||
"github.com/syntrex/gomcp/internal/domain/synapse"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/alert"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/entropy"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/peer"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/synapse"
|
||||
)
|
||||
|
||||
// Config holds orchestrator configuration.
|
||||
|
|
|
|||
|
|
@ -8,8 +8,8 @@ import (
|
|||
|
||||
"github.com/stretchr/testify/assert"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex/gomcp/internal/domain/peer"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/peer"
|
||||
)
|
||||
|
||||
func newTestOrchestrator(t *testing.T, cfg Config) (*Orchestrator, *inMemoryStore) {
|
||||
|
|
|
|||
|
|
@ -6,8 +6,8 @@ import (
|
|||
"encoding/json"
|
||||
"fmt"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex/gomcp/internal/domain/session"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/session"
|
||||
)
|
||||
|
||||
// Provider serves MCP resources (rlm://state, rlm://facts, rlm://stats).
|
||||
|
|
|
|||
|
|
@ -5,9 +5,9 @@ import (
|
|||
"encoding/json"
|
||||
"testing"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex/gomcp/internal/domain/session"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/sqlite"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/session"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/sqlite"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@ package shadow_ai
|
|||
import (
|
||||
"time"
|
||||
|
||||
domsoc "github.com/syntrex/gomcp/internal/domain/soc"
|
||||
domsoc "github.com/syntrex-lab/gomcp/internal/domain/soc"
|
||||
)
|
||||
|
||||
// ShadowAICorrelationRules returns SOC correlation rules specific to Shadow AI
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@ import (
|
|||
"net/http"
|
||||
"time"
|
||||
|
||||
domsoc "github.com/syntrex/gomcp/internal/domain/soc"
|
||||
domsoc "github.com/syntrex-lab/gomcp/internal/domain/soc"
|
||||
)
|
||||
|
||||
// BusClient sends security events to the SOC Event Bus via HTTP POST.
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@ import (
|
|||
"strconv"
|
||||
"strings"
|
||||
|
||||
domsoc "github.com/syntrex/gomcp/internal/domain/soc"
|
||||
domsoc "github.com/syntrex-lab/gomcp/internal/domain/soc"
|
||||
)
|
||||
|
||||
// Parser converts a raw log line into a SOCEvent.
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@ import (
|
|||
"sort"
|
||||
"time"
|
||||
|
||||
domsoc "github.com/syntrex/gomcp/internal/domain/soc"
|
||||
domsoc "github.com/syntrex-lab/gomcp/internal/domain/soc"
|
||||
)
|
||||
|
||||
// ─── Analytics Types ──────────────────────────────────────
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ import (
|
|||
"testing"
|
||||
"time"
|
||||
|
||||
domsoc "github.com/syntrex/gomcp/internal/domain/soc"
|
||||
domsoc "github.com/syntrex-lab/gomcp/internal/domain/soc"
|
||||
)
|
||||
|
||||
func TestGenerateReport_EmptyEvents(t *testing.T) {
|
||||
|
|
|
|||
|
|
@ -13,9 +13,9 @@ import (
|
|||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
|
||||
domsoc "github.com/syntrex/gomcp/internal/domain/soc"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/audit"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/sqlite"
|
||||
domsoc "github.com/syntrex-lab/gomcp/internal/domain/soc"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/audit"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/sqlite"
|
||||
)
|
||||
|
||||
// newTestServiceWithLogger creates a SOC service backed by in-memory SQLite WITH a decision logger.
|
||||
|
|
|
|||
|
|
@ -8,9 +8,9 @@ import (
|
|||
|
||||
"github.com/stretchr/testify/require"
|
||||
|
||||
domsoc "github.com/syntrex/gomcp/internal/domain/soc"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/audit"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/sqlite"
|
||||
domsoc "github.com/syntrex-lab/gomcp/internal/domain/soc"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/audit"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/sqlite"
|
||||
)
|
||||
|
||||
// newBenchService creates a minimal SOC service for benchmarking.
|
||||
|
|
|
|||
|
|
@ -10,9 +10,9 @@ import (
|
|||
"testing"
|
||||
"time"
|
||||
|
||||
domsoc "github.com/syntrex/gomcp/internal/domain/soc"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/audit"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/sqlite"
|
||||
domsoc "github.com/syntrex-lab/gomcp/internal/domain/soc"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/audit"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/sqlite"
|
||||
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
||||
|
|
|
|||
|
|
@ -15,10 +15,10 @@ import (
|
|||
"sync"
|
||||
"time"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/oracle"
|
||||
"github.com/syntrex/gomcp/internal/domain/peer"
|
||||
domsoc "github.com/syntrex/gomcp/internal/domain/soc"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/audit"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/oracle"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/peer"
|
||||
domsoc "github.com/syntrex-lab/gomcp/internal/domain/soc"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/audit"
|
||||
)
|
||||
|
||||
const (
|
||||
|
|
|
|||
|
|
@ -7,8 +7,8 @@ import (
|
|||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
|
||||
domsoc "github.com/syntrex/gomcp/internal/domain/soc"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/sqlite"
|
||||
domsoc "github.com/syntrex-lab/gomcp/internal/domain/soc"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/sqlite"
|
||||
)
|
||||
|
||||
// newTestService creates a SOC service backed by in-memory SQLite, without a decision logger.
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ import (
|
|||
"sync"
|
||||
"time"
|
||||
|
||||
domsoc "github.com/syntrex/gomcp/internal/domain/soc"
|
||||
domsoc "github.com/syntrex-lab/gomcp/internal/domain/soc"
|
||||
)
|
||||
|
||||
// WebhookConfig holds SOAR webhook settings.
|
||||
|
|
|
|||
|
|
@ -13,8 +13,8 @@ import (
|
|||
"strings"
|
||||
"time"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/entropy"
|
||||
"github.com/syntrex/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/entropy"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/memory"
|
||||
)
|
||||
|
||||
// ApathySignal represents a detected infrastructure apathy pattern.
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ import (
|
|||
"context"
|
||||
"fmt"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/causal"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/causal"
|
||||
)
|
||||
|
||||
// CausalService implements MCP tool logic for causal reasoning chains.
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ import (
|
|||
"context"
|
||||
"testing"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/sqlite"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/sqlite"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@ package tools
|
|||
import (
|
||||
"context"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/crystal"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/crystal"
|
||||
)
|
||||
|
||||
// CrystalService implements MCP tool logic for code crystal operations.
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ import (
|
|||
"context"
|
||||
"testing"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/sqlite"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/sqlite"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@ import (
|
|||
"encoding/json"
|
||||
"fmt"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/memory"
|
||||
)
|
||||
|
||||
// FactService implements MCP tool logic for hierarchical fact operations.
|
||||
|
|
|
|||
|
|
@ -4,8 +4,8 @@ import (
|
|||
"context"
|
||||
"testing"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/sqlite"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/sqlite"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
||||
|
|
|
|||
|
|
@ -6,8 +6,8 @@ import (
|
|||
"context"
|
||||
"fmt"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/intent"
|
||||
"github.com/syntrex/gomcp/internal/domain/vectorstore"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/intent"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/vectorstore"
|
||||
)
|
||||
|
||||
// IntentService provides MCP tool logic for intent distillation.
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@ import (
|
|||
"strings"
|
||||
"time"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/memory"
|
||||
)
|
||||
|
||||
// ProjectPulse generates auto-documentation from L0/L1 facts (v3.7 Cerebro).
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ import (
|
|||
"context"
|
||||
"fmt"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/session"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/session"
|
||||
)
|
||||
|
||||
// SessionService implements MCP tool logic for cognitive state operations.
|
||||
|
|
|
|||
|
|
@ -4,8 +4,8 @@ import (
|
|||
"context"
|
||||
"testing"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/session"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/sqlite"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/session"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/sqlite"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ import (
|
|||
"context"
|
||||
"fmt"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/synapse"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/synapse"
|
||||
)
|
||||
|
||||
// SynapseService implements MCP tool logic for synapse operations.
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@ import (
|
|||
"runtime"
|
||||
"time"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/memory"
|
||||
)
|
||||
|
||||
// Version info set at build time via ldflags.
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ import (
|
|||
"context"
|
||||
"testing"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/sqlite"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/sqlite"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ import (
|
|||
"testing"
|
||||
"time"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/alert"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/alert"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@ import (
|
|||
"time"
|
||||
"unicode"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/memory"
|
||||
)
|
||||
|
||||
// Default configuration values.
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ import (
|
|||
"testing"
|
||||
"time"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/memory"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ import (
|
|||
"sort"
|
||||
"strings"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/memory"
|
||||
)
|
||||
|
||||
// RelevanceScorer computes relevance scores for facts based on multiple signals:
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ import (
|
|||
"testing"
|
||||
"time"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/memory"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@ package mimicry
|
|||
import (
|
||||
"testing"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/oracle"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/oracle"
|
||||
"github.com/stretchr/testify/assert"
|
||||
)
|
||||
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ import (
|
|||
"regexp"
|
||||
"strings"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/entropy"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/entropy"
|
||||
)
|
||||
|
||||
// SecretScanResult holds the result of scanning content for secrets.
|
||||
|
|
|
|||
|
|
@ -11,8 +11,8 @@ import (
|
|||
"regexp"
|
||||
"strings"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/crystal"
|
||||
"github.com/syntrex/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/crystal"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/memory"
|
||||
)
|
||||
|
||||
// ThreatFinding represents a single finding from the threat model scanner.
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ import (
|
|||
"encoding/json"
|
||||
"testing"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/crystal"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/crystal"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
||||
|
|
|
|||
|
|
@ -15,10 +15,10 @@ import (
|
|||
"fmt"
|
||||
"time"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/circuitbreaker"
|
||||
"github.com/syntrex/gomcp/internal/domain/entropy"
|
||||
"github.com/syntrex/gomcp/internal/domain/intent"
|
||||
"github.com/syntrex/gomcp/internal/domain/oracle"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/circuitbreaker"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/entropy"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/intent"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/oracle"
|
||||
)
|
||||
|
||||
// Stage represents a processing stage.
|
||||
|
|
|
|||
|
|
@ -6,9 +6,9 @@ import (
|
|||
|
||||
"github.com/stretchr/testify/assert"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/circuitbreaker"
|
||||
"github.com/syntrex/gomcp/internal/domain/entropy"
|
||||
"github.com/syntrex/gomcp/internal/domain/oracle"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/circuitbreaker"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/entropy"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/oracle"
|
||||
)
|
||||
|
||||
func TestPipeline_AllowsNormalText(t *testing.T) {
|
||||
|
|
|
|||
|
|
@ -18,7 +18,7 @@ import (
|
|||
"fmt"
|
||||
"time"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/vectorstore"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/vectorstore"
|
||||
)
|
||||
|
||||
// Decision represents a routing decision.
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@ import (
|
|||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/vectorstore"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/vectorstore"
|
||||
)
|
||||
|
||||
func seedStore() *vectorstore.Store {
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ import (
|
|||
"math"
|
||||
"testing"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/vectorstore"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/vectorstore"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ import (
|
|||
"log/slog"
|
||||
"time"
|
||||
|
||||
domsoc "github.com/syntrex/gomcp/internal/domain/soc"
|
||||
domsoc "github.com/syntrex-lab/gomcp/internal/domain/soc"
|
||||
"golang.org/x/crypto/bcrypt"
|
||||
)
|
||||
|
||||
|
|
|
|||
2
internal/infrastructure/cache/bolt_cache.go
vendored
2
internal/infrastructure/cache/bolt_cache.go
vendored
|
|
@ -8,7 +8,7 @@ import (
|
|||
"path/filepath"
|
||||
"sync"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/memory"
|
||||
bolt "go.etcd.io/bbolt"
|
||||
)
|
||||
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@ import (
|
|||
"path/filepath"
|
||||
"testing"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/memory"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@ import (
|
|||
"encoding/json"
|
||||
"fmt"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/vectorstore"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/vectorstore"
|
||||
bolt "go.etcd.io/bbolt"
|
||||
)
|
||||
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ import (
|
|||
"os"
|
||||
"testing"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/vectorstore"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/vectorstore"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
bolt "go.etcd.io/bbolt"
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ import (
|
|||
"sync"
|
||||
"time"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/alert"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/alert"
|
||||
)
|
||||
|
||||
// ---------- State Machine (v3.2) ----------
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@ import (
|
|||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/alert"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/alert"
|
||||
)
|
||||
|
||||
func testConfig(dir string) LeashConfig {
|
||||
|
|
|
|||
|
|
@ -15,9 +15,9 @@ import (
|
|||
"sync"
|
||||
"time"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/alert"
|
||||
"github.com/syntrex/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex/gomcp/internal/domain/peer"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/alert"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/peer"
|
||||
)
|
||||
|
||||
// pipePath returns the platform-specific IPC socket path.
|
||||
|
|
|
|||
|
|
@ -10,10 +10,10 @@ import (
|
|||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/alert"
|
||||
"github.com/syntrex/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex/gomcp/internal/domain/peer"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/ipc"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/alert"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/peer"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/ipc"
|
||||
)
|
||||
|
||||
// mockStore is a minimal in-memory FactStore for testing.
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@ import (
|
|||
|
||||
ort "github.com/yalue/onnxruntime_go"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/vectorstore"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/vectorstore"
|
||||
)
|
||||
|
||||
// Embedder implements vectorstore.Embedder using ONNX Runtime.
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ package onnx
|
|||
import (
|
||||
"log"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/vectorstore"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/vectorstore"
|
||||
)
|
||||
|
||||
// NewEmbedderWithFallback attempts to create an ONNX embedder.
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ package onnx
|
|||
import (
|
||||
"log"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/vectorstore"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/vectorstore"
|
||||
)
|
||||
|
||||
// NewEmbedderWithFallback returns FTS5 fallback embedder when built without ONNX.
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ import (
|
|||
"fmt"
|
||||
"time"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/soc"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/soc"
|
||||
)
|
||||
|
||||
// SOCRepo provides PostgreSQL persistence for SOC events, incidents, and sensors.
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ import (
|
|||
"context"
|
||||
"fmt"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/vectorstore"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/vectorstore"
|
||||
)
|
||||
|
||||
// PyBridgeEmbedder wraps the Python bridge as an Embedder.
|
||||
|
|
|
|||
|
|
@ -111,7 +111,7 @@ func (g *Generator) GenerateSPDX() (*SPDXDocument, error) {
|
|||
Name: g.productName,
|
||||
Version: g.version,
|
||||
License: "Proprietary",
|
||||
DownloadURL: "https://github.com/syntrex/gomcp",
|
||||
DownloadURL: "https://github.com/syntrex-lab/gomcp",
|
||||
}}, g.packages...),
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ import (
|
|||
"fmt"
|
||||
"time"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/causal"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/causal"
|
||||
)
|
||||
|
||||
// CausalRepo implements causal.CausalStore using SQLite.
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ import (
|
|||
"context"
|
||||
"testing"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/causal"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/causal"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@ import (
|
|||
"path/filepath"
|
||||
"strings"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/crystal"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/crystal"
|
||||
)
|
||||
|
||||
// CrystalRepo implements crystal.CrystalStore using SQLite.
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ import (
|
|||
"context"
|
||||
"testing"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/crystal"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/crystal"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@ import (
|
|||
"fmt"
|
||||
"time"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/memory"
|
||||
)
|
||||
|
||||
const timeFormat = time.RFC3339Nano
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ import (
|
|||
"testing"
|
||||
"time"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/memory"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ import (
|
|||
"fmt"
|
||||
"time"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/peer"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/peer"
|
||||
)
|
||||
|
||||
// PeerRepo implements peer.PeerStore using SQLite.
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@ import (
|
|||
"fmt"
|
||||
"time"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/soc"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/soc"
|
||||
)
|
||||
|
||||
// SOCRepo provides SQLite persistence for SOC events, incidents, and sensors.
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ import (
|
|||
"testing"
|
||||
"time"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/soc"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/soc"
|
||||
)
|
||||
|
||||
func setupSOCRepo(t *testing.T) *SOCRepo {
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@ import (
|
|||
"fmt"
|
||||
"time"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/session"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/session"
|
||||
)
|
||||
|
||||
// StateRepo implements session.StateStore using SQLite.
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ import (
|
|||
"context"
|
||||
"testing"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/session"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/session"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ import (
|
|||
"fmt"
|
||||
"time"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/synapse"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/synapse"
|
||||
)
|
||||
|
||||
// SynapseRepo implements synapse.SynapseStore using SQLite.
|
||||
|
|
|
|||
|
|
@ -4,8 +4,8 @@ import (
|
|||
"context"
|
||||
"testing"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/sqlite"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/sqlite"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@ import (
|
|||
"math/rand"
|
||||
"time"
|
||||
|
||||
domsoc "github.com/syntrex/gomcp/internal/domain/soc"
|
||||
domsoc "github.com/syntrex-lab/gomcp/internal/domain/soc"
|
||||
)
|
||||
|
||||
// runDemoSimulator runs a background goroutine that injects
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@ import (
|
|||
"strings"
|
||||
"time"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/application/resilience"
|
||||
"github.com/syntrex-lab/gomcp/internal/application/resilience"
|
||||
)
|
||||
|
||||
// ResilienceAPI holds references to the SARL engines for HTTP handlers.
|
||||
|
|
|
|||
|
|
@ -17,12 +17,12 @@ import (
|
|||
"sync"
|
||||
"time"
|
||||
|
||||
shadowai "github.com/syntrex/gomcp/internal/application/shadow_ai"
|
||||
appsoc "github.com/syntrex/gomcp/internal/application/soc"
|
||||
"github.com/syntrex/gomcp/internal/domain/engines"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/auth"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/email"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/tracing"
|
||||
shadowai "github.com/syntrex-lab/gomcp/internal/application/shadow_ai"
|
||||
appsoc "github.com/syntrex-lab/gomcp/internal/application/soc"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/engines"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/auth"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/email"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/tracing"
|
||||
)
|
||||
|
||||
// Server provides HTTP API endpoints for SOC monitoring.
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@ import (
|
|||
"strconv"
|
||||
"time"
|
||||
|
||||
shadowai "github.com/syntrex/gomcp/internal/application/shadow_ai"
|
||||
shadowai "github.com/syntrex-lab/gomcp/internal/application/shadow_ai"
|
||||
)
|
||||
|
||||
// --- GET /api/v1/shadow-ai/stats ---
|
||||
|
|
|
|||
|
|
@ -13,10 +13,10 @@ import (
|
|||
"sync"
|
||||
"time"
|
||||
|
||||
appsoc "github.com/syntrex/gomcp/internal/application/soc"
|
||||
"github.com/syntrex/gomcp/internal/domain/engines"
|
||||
domsoc "github.com/syntrex/gomcp/internal/domain/soc"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/auth"
|
||||
appsoc "github.com/syntrex-lab/gomcp/internal/application/soc"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/engines"
|
||||
domsoc "github.com/syntrex-lab/gomcp/internal/domain/soc"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/auth"
|
||||
)
|
||||
|
||||
// MaxRequestBodySize limits POST body size to prevent OOM (T3-3).
|
||||
|
|
|
|||
|
|
@ -8,9 +8,9 @@ import (
|
|||
"net/http/httptest"
|
||||
"testing"
|
||||
|
||||
appsoc "github.com/syntrex/gomcp/internal/application/soc"
|
||||
domsoc "github.com/syntrex/gomcp/internal/domain/soc"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/sqlite"
|
||||
appsoc "github.com/syntrex-lab/gomcp/internal/application/soc"
|
||||
domsoc "github.com/syntrex-lab/gomcp/internal/domain/soc"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/sqlite"
|
||||
)
|
||||
|
||||
// newTestServer creates an HTTP test server with a real SOC service backed by in-memory SQLite.
|
||||
|
|
|
|||
|
|
@ -10,19 +10,19 @@ import (
|
|||
"github.com/mark3labs/mcp-go/mcp"
|
||||
"github.com/mark3labs/mcp-go/server"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/application/contextengine"
|
||||
"github.com/syntrex/gomcp/internal/application/orchestrator"
|
||||
"github.com/syntrex/gomcp/internal/application/resources"
|
||||
appsoc "github.com/syntrex/gomcp/internal/application/soc"
|
||||
"github.com/syntrex/gomcp/internal/application/tools"
|
||||
"github.com/syntrex/gomcp/internal/domain/circuitbreaker"
|
||||
entropyPkg "github.com/syntrex/gomcp/internal/domain/entropy"
|
||||
"github.com/syntrex/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex/gomcp/internal/domain/oracle"
|
||||
"github.com/syntrex/gomcp/internal/domain/peer"
|
||||
"github.com/syntrex/gomcp/internal/domain/pipeline"
|
||||
"github.com/syntrex/gomcp/internal/domain/router"
|
||||
"github.com/syntrex/gomcp/internal/domain/vectorstore"
|
||||
"github.com/syntrex-lab/gomcp/internal/application/contextengine"
|
||||
"github.com/syntrex-lab/gomcp/internal/application/orchestrator"
|
||||
"github.com/syntrex-lab/gomcp/internal/application/resources"
|
||||
appsoc "github.com/syntrex-lab/gomcp/internal/application/soc"
|
||||
"github.com/syntrex-lab/gomcp/internal/application/tools"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/circuitbreaker"
|
||||
entropyPkg "github.com/syntrex-lab/gomcp/internal/domain/entropy"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/memory"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/oracle"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/peer"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/pipeline"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/router"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/vectorstore"
|
||||
)
|
||||
|
||||
// Server wraps the MCP server with all registered tools and resources.
|
||||
|
|
|
|||
|
|
@ -9,9 +9,9 @@ import (
|
|||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
|
||||
"github.com/syntrex/gomcp/internal/application/resources"
|
||||
"github.com/syntrex/gomcp/internal/application/tools"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/sqlite"
|
||||
"github.com/syntrex-lab/gomcp/internal/application/resources"
|
||||
"github.com/syntrex-lab/gomcp/internal/application/tools"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/sqlite"
|
||||
)
|
||||
|
||||
// newTestServer creates a fully-wired Server backed by in-memory SQLite databases.
|
||||
|
|
|
|||
|
|
@ -8,9 +8,9 @@ import (
|
|||
|
||||
"github.com/mark3labs/mcp-go/mcp"
|
||||
|
||||
appsoc "github.com/syntrex/gomcp/internal/application/soc"
|
||||
"github.com/syntrex/gomcp/internal/application/tools"
|
||||
domsoc "github.com/syntrex/gomcp/internal/domain/soc"
|
||||
appsoc "github.com/syntrex-lab/gomcp/internal/application/soc"
|
||||
"github.com/syntrex-lab/gomcp/internal/application/tools"
|
||||
domsoc "github.com/syntrex-lab/gomcp/internal/domain/soc"
|
||||
)
|
||||
|
||||
// SetSOCService enables SOC tools (soc_ingest, soc_events, soc_incidents, soc_sensors, soc_dashboard).
|
||||
|
|
|
|||
|
|
@ -9,11 +9,11 @@ import (
|
|||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
|
||||
appsoc "github.com/syntrex/gomcp/internal/application/soc"
|
||||
"github.com/syntrex/gomcp/internal/domain/peer"
|
||||
domsoc "github.com/syntrex/gomcp/internal/domain/soc"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/audit"
|
||||
"github.com/syntrex/gomcp/internal/infrastructure/sqlite"
|
||||
appsoc "github.com/syntrex-lab/gomcp/internal/application/soc"
|
||||
"github.com/syntrex-lab/gomcp/internal/domain/peer"
|
||||
domsoc "github.com/syntrex-lab/gomcp/internal/domain/soc"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/audit"
|
||||
"github.com/syntrex-lab/gomcp/internal/infrastructure/sqlite"
|
||||
)
|
||||
|
||||
// newTestServerWithSOC extends newTestServer with a fully wired SOC Service.
|
||||
|
|
|
|||
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Add a link
Reference in a new issue