MCPcopy Create free account

hub / github.com/JuliusBrussee/caveman / functions

Functions8,152 in github.com/JuliusBrussee/caveman

↓ 9 callersFunctionfrontierDialCandidate
(model string, expectedCost, qualityLCB float64, latencyMS int)
proxy/routing/routing_test.go:421
↓ 9 callersFunctionfrontierDialFeatures
()
proxy/routing/routing_test.go:410
↓ 9 callersFunctiongatewayFindObjectField
(body []byte, obj gatewayJSONSpan, field string)
proxy/internal/gateway/retrieve_tool.go:142
↓ 9 callersFunctiongatewayHostPort
(gw = gatewayURL())
packages/cli/src/index.ts:16018
↓ 9 callersMethodlookupTarget
(uid string)
browse/session.go:347
↓ 9 callersFunctionnewBodyCapture
newBodyCapture returns nil when capture is off, so the hot path costs one nil check. A directory that cannot be created disables capture rather than f
proxy/internal/gateway/capture.go:79
↓ 9 callersFunctionnewCompressTestServer
(t *testing.T, upstream string, sink TelemetrySink, comp Compressor)
proxy/internal/gateway/compress_test.go:103
↓ 9 callersFunctionnewToolSchemaStripServer
(t *testing.T, comp Compressor, rt *captureTransport, cfg Config)
proxy/internal/gateway/toolschema_strip_test.go:89
↓ 9 callersFunctionobservedOpenAIRecords
(count int, quality bool)
cacheengine/cachebench/cachebench_test.go:442
↓ 9 callersFunctionopen
()
mem/cmd/cavemem/main.go:89
↓ 9 callersMethodpriceInputTokens
priceInputTokens converts a token quantity into USD at the user's own measured effective input rate. Every sink in the report is input-side (context r
proxy/internal/store/learn_pricing.go:319
↓ 9 callersFunctionreadMcpServerMarker
(agent: string, serverName: string)
packages/cli/src/index.ts:2576
↓ 9 callersMethodresult
()
packages/agent/src/adapters.ts:229
↓ 9 callersFunctionscanSessionSourceUntil
(source sessionSource, since time.Time, slugs []string, beh *behaviorScan, miner *recurringMiner, deadline *be
proxy/internal/store/session_source.go:296
↓ 9 callersFunctionshould_compress
Return True if the file is natural language and should be compressed.
skills/caveman-compress/scripts/detect.py:118
↓ 9 callersFunctionsleep
(ms: number)
packages/cli/src/index.ts:8925
↓ 9 callersFunctionsummarizeElided
summarizeElided renders the facts that hold across every unit of one elided run, or "" when there are none, extraction found no structure, or the summ
engine/compressors/invariants.go:180
↓ 9 callersFunctiontlsClientConfig
tlsClientConfig builds the ClickHouse TLS configuration from the environment, or (nil, nil) when no CLICKHOUSE_TLS_* knob is set — in which case calle
shared/platform/chhttp/chhttp.go:119
↓ 9 callersFunctionwholeBody
(b []byte)
proxy/internal/gateway/capture.go:148
↓ 9 callersFunctionwrapRuntimeConfig
(options: { forStart?: boolean } = {})
packages/cli/src/index.ts:3342
↓ 8 callersFunctionAnthropicImageTokens
AnthropicImageTokens returns the Anthropic input-token cost of a w×h image under tier, without the safety margin (callers apply ImageCostSafetyMargin)
engine/pixel/pricing.go:42
↓ 8 callersMethodApply
(context.Context, NativeRequest, Plan)
cacheengine/types.go:169
↓ 8 callersFunctionBool
(name string, fallback bool)
shared/platform/env/env.go:21
↓ 8 callersFunctionDecrypt
Decrypt reverses Encrypt: it expects nonce(12) || ciphertext+tag.
shared/platform/secretbox/secretbox.go:104
↓ 8 callersMethodDecrypt
Decrypt unwraps versioned KMS envelope. Metadata can choose only validated key identity under configured provider; it can never choose host or token.
shared/platform/kms/kms.go:222
↓ 8 callersFunctionGenerateTrace
GenerateTrace builds deterministic provider-native real-agent-shaped requests.
cacheengine/cachebench/trace.go:26
↓ 8 callersFunctionLookup
Lookup returns the Info for a class. The second return is false for an unknown class — callers fail closed (treat an unknown class as unsafe to run).
engine/safety/safety.go:53
↓ 8 callersFunctionNew
New constructs the Bedrock adapter. baseURL is the bedrock-runtime endpoint; in production it is the regional endpoint (https://bedrock-runtime.<regio
proxy/providers/bedrock/bedrock.go:33
↓ 8 callersFunctionNew
()
shared/platform/cacheguard/cacheguard.go:67
↓ 8 callersFunctionNewHTML
NewHTML returns the default HTML article extractor.
engine/compressors/html.go:38
↓ 8 callersFunctionNewInsertClient
NewInsertClient returns an *http.Client bounded for ClickHouse inserts.
shared/platform/chhttp/chhttp.go:278
↓ 8 callersFunctionOpen
Open opens (creating if needed) a cavemem store.
mem/store.go:94
↓ 8 callersFunctionRenderChunkToPNG
(text string, cols int, style RenderStyle, maxHeightPx int, slotText string)
engine/pixel/render.go:423
↓ 8 callersFunctionRenderTextToPNGsMultiCol
(text string, cols, numCols int)
engine/pixel/render.go:768
↓ 8 callersMethodSanitizeAndMapHeaders
(ctx context.Context, req *http.Request, credential Credential, _ *url.URL)
proxy/providers/adapter.go:429
↓ 8 callersFunctionWrapLines
(text string, cols, markerScale int)
engine/pixel/render.go:194
↓ 8 callersFunction_cave
()
packages/sdk/python/tests/test_tool_events.py:46
↓ 8 callersFunctionbold
(s: string)
packages/cli/src/index.ts:15819
↓ 8 callersFunctioncachePointsEnabled
()
proxy/providers/bedrock/cache_points_test.go:15
↓ 8 callersMethodcanvas
--- Page geometry derived from a render profile --------------------------- A page is drawn as: rows advance by PitchY with an 8px-tall glyph, so the
engine/pixel/density.go:170
↓ 8 callersFunctionclose
()
packages/agent/tests/claude.runtime.mjs:265
↓ 8 callersFunctioncompactMeta
(v map[string]any)
proxy/internal/store/usage_import.go:669
↓ 8 callersFunctioncontentBlocks
(content any)
engine/pixel/transform_anthropic.go:1355
↓ 8 callersFunctioncreation
The session ledger is the accounting the harm tripwire reads, and the freeze registry every lever consults. Its contract: bounded, session-scoped, one
proxy/internal/gateway/ledger_test.go:14
↓ 8 callersFunctionfindObjectField
(body []byte, obj jsonSpan, field string)
proxy/providers/anthropic/splice.go:37
↓ 8 callersFunctiongatewayDecodeJSONString
(raw []byte)
proxy/internal/gateway/pixel.go:551
↓ 8 callersFunctiongenPNG
(t *testing.T, w, h int)
engine/image/image_test.go:13
↓ 8 callersFunctiongetObject
(root: unknown, path: string[])
packages/cli/src/index.ts:5841
↓ 8 callersFunctionheaders
( cave: Cave, workflow: str, upstream_key: str | None = None, latency_class: str | None = None
packages/sdk/python/caveman_cloud/core.py:1457
↓ 8 callersFunctionheaders
(cave: Cave, workflow: string, upstreamKey?: string, hint?: Record<string, unknown>, trace?: TraceContext)
packages/sdk/typescript/src/index.ts:2091
↓ 8 callersFunctionisRecord
(value: unknown)
packages/sdk/typescript/src/index.ts:1390
↓ 8 callersFunctionjsonStr
jsonStr quotes s as a JSON string literal for embedding in a request line.
mcp/server_test.go:764
↓ 8 callersFunctionmustHome
(logger *slog.Logger)
proxy/cmd/caveman-proxy/main.go:944
↓ 8 callersFunctionmutateRawConfig
(fn: (out: Record<string, unknown>) => void)
packages/cli/src/index.ts:3791
↓ 8 callersFunctionnativeHooksDocument
(agentId: "claude" | "codex" | "gemini", includeShrink: boolean, base: Record<string, unknown> = {}, includeRe
packages/cli/src/index.ts:6166
↓ 8 callersFunctionnewSessionLedger
()
proxy/internal/gateway/ledger.go:100
↓ 8 callersFunctionpaint
(code: string, s: string)
packages/cli/src/index.ts:15816
↓ 8 callersFunctionportListening
(host: string, port: number)
packages/cli/src/index.ts:15995
↓ 8 callersMethodprepare
(ctx context.Context, records []TraceRecord)
cacheengine/cachebench/replay.go:501
↓ 8 callersFunctionreadIdentifierToken
(source: string, start: number)
packages/agent/src/source-graph.ts:689
↓ 8 callersFunctionreadNativeJournal
(agent: string)
packages/cli/src/index.ts:7399
↓ 8 callersFunctionrealEngine
(t *testing.T)
mcp/server_test.go:76
↓ 8 callersMethodremaining
Budget available to a new reservation right now.
packages/agent/src/budget.ts:309
↓ 8 callersFunctionresolve
(t *testing.T, rawurl string)
proxy/providers/azureopenai/azure_routing_test.go:11
↓ 8 callersFunctionretroLogPayload
--- fixtures --------------------------------------------------------------- retroLogPayload builds a repetitive tool-result body the engine can actua
proxy/internal/store/learn_retro_test.go:22
↓ 8 callersFunctionretroRepeatedBlock
retroRepeatedBlock is one paragraph heavy enough to clear minBlockTokens.
proxy/internal/store/learn_retro_test.go:31
↓ 8 callersFunctionsetKey
(t *testing.T)
shared/platform/secretbox/secretbox_test.go:9
↓ 8 callersFunctionstreamUsageEnabled
C8 review finding 5: this optimizer adds a client-visible SSE chunk to the response (an observable effect outside what byte-safe promises), so like re
proxy/providers/openai/stream_usage_test.go:13
↓ 8 callersFunctionsubagent
(options: { name: string; description: string; agent: AgentDefinition; timeoutMs?: number; maxInputC
packages/agent/src/index.ts:146
↓ 8 callersFunctionsum
(pick: (bill: TurnBill) => number)
packages/agent/src/code.ts:837
↓ 8 callersFunctiontelemetryState
()
packages/cli/src/index.ts:523
↓ 8 callersFunctiontimestampFromObject
(obj map[string]any)
proxy/internal/store/usage_import.go:494
↓ 8 callersFunctiontoString
(v any)
engine/pixel/transform_anthropic.go:1519
↓ 8 callersFunctionunitPrice
(p cost.Price)
proxy/routing/routing.go:335
↓ 7 callersFunctionCanonicalDetail
CanonicalDetail returns the deterministic JSON encoding of a detail blob: keys sorted (Go's encoding/json sorts map keys recursively), whitespace stri
shared/platform/proposalrun/proposalrun.go:56
↓ 7 callersFunctionCompactSlabWhitespace
(text string)
engine/pixel/textprep.go:234
↓ 7 callersFunctionDecodeTOON
DecodeTOON parses the supported TOON subset back into the JSON data model.
engine/compressors/toon_decode.go:23
↓ 7 callersMethodEncrypt
Encrypt delegates encryption to key manager.
shared/platform/kms/kms.go:175
↓ 7 callersFunctionNewAXTree
NewAXTree returns the forced-only CDP Accessibility.getFullAXTree compressor. It emits a compact, deterministic indented view with uid handles while C
engine/compressors/axtree.go:28
↓ 7 callersFunctionNewCDPDriver
(parent context.Context, opts CDPOptions)
browse/cdp.go:39
↓ 7 callersFunctionNewConfig
NewConfig returns the deterministic YAML, TOML, and INI compressor.
engine/compressors/config.go:40
↓ 7 callersFunctionNewEngineCompressor
NewEngineCompressor builds the engine-backed compressor over a CCR store. The engine shares that store, so a handle returned by StoreOriginal resolves
proxy/internal/standalone/standalone.go:187
↓ 7 callersFunctionNewTerminal
NewTerminal returns the default terminal/command-output compressor.
engine/compressors/terminal.go:53
↓ 7 callersMethodNewUsageScanner
NewUsageScanner returns a sink that the proxy tees the upstream response through. It captures usage from both whole-body (non-stream) and SSE/JSONL (s
proxy/providers/adapter.go:329
↓ 7 callersFunctionNormalizeRawCacheUsage
NormalizeRawCacheUsage maps official cache counters into UsageObservation. Unknown providers, duplicate keys, negative/fractional counters, ambiguous
cacheengine/raw_usage.go:166
↓ 7 callersFunctionParsePoolConfig
ParsePoolConfig validates the connection string and applies the managed database CA to every TLS path. Production rejects sslmode=require because it e
shared/platform/postgresconfig/postgresconfig.go:29
↓ 7 callersFunctionProjectAnthropic
ProjectAnthropic projects a Messages request onto the provider's current count_tokens input surface. Every proven count field is copied as its raw JSO
proxy/providers/internal/counttokens/counttokens.go:62
↓ 7 callersFunctionReadTraceJSONL
ReadTraceJSONL reads trace records using conservative default resource limits.
cacheengine/cachebench/trace.go:274
↓ 7 callersFunctionRenderTextToTwoLayerPNGs
RenderTextToTwoLayerPNGs splits wrapped text into max-level overlay pages. Each image holds up to 2×N lines: the first N in the red layer, the next N
engine/pixel/overlay.go:189
↓ 7 callersFunctionResolveGptProfile
(model string)
engine/pixel/gpt_profiles.go:53
↓ 7 callersMethodSafetyClass
SafetyClass is the compressor's inherent class on the S0–S4 ladder.
engine/compressors/compressor.go:26
↓ 7 callersFunctionShrink
Shrink compresses a tool catalog with an S4 lossy transform. It is fail-open: on any parse problem or when the result would not be smaller, it returns
shrink/shrink.go:117
↓ 7 callersMethodSign
Sign computes the SigV4 signature for req against the given payload and sets the Authorization, X-Amz-Date, X-Amz-Content-Sha256 (and, when present, X
shared/platform/awssig/awssig.go:65
↓ 7 callersFunctionStringField
(body []byte, object Span, name string)
proxy/providers/jsonsplice/jsonsplice.go:95
↓ 7 callersFunctionStripToolSchemaAnnotations
StripToolSchemaAnnotations removes the annotationDropKeys keywords from a serialized tool catalog (the provider `tools` array) and returns ok=false wi
engine/compressors/toolschema_annotations.go:97
↓ 7 callersMethodSupersede
Supersede atomically replaces one current memory with a new current version. The old row remains durable for history and byte-exact audit, but normal
mem/store.go:201
↓ 7 callersFunctionToolRawText
ToolRawText wraps a raw string (e.g. recovered original bytes) as text content.
mcp/protocol.go:79
↓ 7 callersFunctionToolText
ToolText wraps a value as a single JSON text content item (the agent receives JSON it can parse).
mcp/protocol.go:70
↓ 7 callersFunctionValidateHost
ValidateHost resolves host (bare hostname or IP literal) and checks all resolved addresses. Use when you have a host/port pair rather than a full URL
shared/platform/ssrf/ssrf.go:193
↓ 7 callersFunctionWriteTraceJSONL
WriteTraceJSONL writes strict replayable trace v3 records.
cacheengine/cachebench/trace.go:228
← previousnext →301–400 of 8,152, ranked by callers