code-graph-context 2.12.4 → 2.12.5

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.
package/README.md CHANGED
@@ -190,6 +190,7 @@ If you prefer to edit the config files directly:
190
190
  | `NEO4J_USER` | No | `neo4j` | Neo4j username |
191
191
  | `NEO4J_PASSWORD` | No | `PASSWORD` | Neo4j password |
192
192
  | `EMBEDDING_MODEL` | No | `codesage/codesage-base-v2` | Local embedding model (see [Embedding Configuration](#embedding-configuration)) |
193
+ | `EMBEDDING_BATCH_SIZE` | No | `16` | Texts per embedding batch (lower = less memory, higher = faster) |
193
194
  | `EMBEDDING_SIDECAR_PORT` | No | `8787` | Port for local embedding server |
194
195
  | `EMBEDDING_DEVICE` | No | auto (`mps`/`cpu`) | Device for embeddings. Auto-detects MPS on Apple Silicon |
195
196
  | `EMBEDDING_HALF_PRECISION` | No | `false` | Set `true` for float16 (uses ~0.5x memory) |
@@ -1,12 +1,12 @@
1
1
  /**
2
2
  * Local Embeddings Service
3
- * Uses a Python sidecar running Qodo-Embed-1-1.5B (or configurable model).
3
+ * Uses a Python sidecar running CodeSage-Base-v2 (or configurable model).
4
4
  * Default provider — no API key required.
5
5
  */
6
6
  import { debugLog } from '../../mcp/utils.js';
7
7
  import { getEmbeddingSidecar } from './embedding-sidecar.js';
8
8
  const BATCH_CONFIG = {
9
- maxBatchSize: 8, // Small batches — 1.5B model on MPS OOMs at higher values on 16GB machines
9
+ maxBatchSize: parseInt(process.env.EMBEDDING_BATCH_SIZE ?? '', 10) || 16,
10
10
  };
11
11
  export class LocalEmbeddingsService {
12
12
  async embedText(text) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "code-graph-context",
3
- "version": "2.12.4",
3
+ "version": "2.12.5",
4
4
  "description": "MCP server that builds code graphs to provide rich context to LLMs",
5
5
  "type": "module",
6
6
  "homepage": "https://github.com/drewdrewH/code-graph-context#readme",