Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/akitaonrails/FrankClaw
/ functions
Functions
2,115 in github.com/akitaonrails/FrankClaw
⨍
Functions
2,115
◇
Types & classes
423
↓ 340 callers
Method
as_str
(&self)
crates/frankclaw-core/src/types.rs:25
↓ 334 callers
Method
is_empty
Whether the cache is empty.
crates/frankclaw-models/src/cache.rs:151
↓ 195 callers
Method
len
Number of entries currently in the cache.
crates/frankclaw-models/src/cache.rs:146
↓ 186 callers
Method
push
(&mut self, chunk: &[u8])
crates/frankclaw-models/src/sse.rs:15
↓ 135 callers
Method
push
(&mut self, chunk: &str)
crates/frankclaw-channels/src/signal.rs:218
↓ 111 callers
Method
get
(&self, id: &ChannelId)
crates/frankclaw-channels/src/lib.rs:59
↓ 98 callers
Method
get
(&self, _key: &SessionKey)
crates/frankclaw-tools/src/lib.rs:293
↓ 95 callers
Method
get
(&self, canvas_id: &str)
crates/frankclaw-gateway/src/canvas.rs:139
↓ 86 callers
Method
ok
(id: RequestId, result: serde_json::Value)
crates/frankclaw-core/src/protocol.rs:179
↓ 82 callers
Method
channel_err
Build a channel error for this adapter.
crates/frankclaw-core/src/channel.rs:172
↓ 69 callers
Function
temp_dir
()
crates/frankclaw-gateway/src/methods.rs:948
↓ 57 callers
Method
send
Broadcast a JSON-serialized event to all subscribers. Returns the number of receivers that got the message.
crates/frankclaw-gateway/src/broadcast.rs:20
↓ 47 callers
Method
register
(&mut self, tool: Arc<dyn Tool>)
crates/frankclaw-tools/src/lib.rs:191
↓ 45 callers
Function
default_agent
()
crates/frankclaw-core/src/types.rs:137
↓ 34 callers
Method
path
(&self)
crates/frankclaw-gateway/src/test_fixtures.rs:18
↓ 31 callers
Method
text
Create a simple text message (no tool calls).
crates/frankclaw-core/src/model.rs:88
↓ 30 callers
Method
remove
(&self, id: &str)
crates/frankclaw-cron/src/service.rs:220
↓ 26 callers
Method
as_bytes
Access the raw key bytes. Use sparingly — prefer `derive_subkey`.
crates/frankclaw-crypto/src/keys.rs:49
↓ 26 callers
Method
chat
(&self, request: ChatRequest)
crates/frankclaw-runtime/src/lib.rs:310
↓ 25 callers
Method
invoke_allowed
( &self, allowed_tools: &[String], name: &str, args: serde_json::Value,
crates/frankclaw-tools/src/lib.rs:215
↓ 24 callers
Method
count
Number of plugins.
crates/frankclaw-plugin-sdk/src/lifecycle.rs:110
↓ 24 callers
Function
score_complexity
Score a prompt's complexity across 13 dimensions using default config.
crates/frankclaw-models/src/routing.rs:301
↓ 23 callers
Function
log_failure
(action: &str, details: Value)
crates/frankclaw-gateway/src/audit.rs:13
↓ 23 callers
Method
parse
Parse back into components. Returns None if format is invalid.
crates/frankclaw-core/src/types.rs:74
↓ 23 callers
Method
with
Add a context value.
crates/frankclaw-core/src/hooks.rs:63
↓ 21 callers
Method
get_transcript
(&self, _key: &SessionKey, _limit: usize, _before: Option<u64>)
crates/frankclaw-tools/src/lib.rs:298
↓ 20 callers
Method
transition_to
Transition to a new state, recording the transition with an optional reason. Returns `Err` if the transition is invalid.
crates/frankclaw-cron/src/job.rs:145
↓ 19 callers
Method
upsert
(&self, entry: &SessionEntry)
crates/frankclaw-sessions/src/store.rs:239
↓ 18 callers
Function
load_config
( path: Option<&std::path::Path>, state_dir: &std::path::Path, )
crates/frankclaw-cli/src/main.rs:1188
↓ 18 callers
Method
register_spawn
Attempt to register a new subagent run. Returns `SpawnResult::Accepted` with run details if the spawn is allowed, or `SpawnResult::Rejected` if limit
crates/frankclaw-runtime/src/subagent.rs:160
↓ 18 callers
Method
store
Store a response in the cache. Skips storage if the request has tool definitions.
crates/frankclaw-models/src/cache.rs:107
↓ 18 callers
Method
validate
(&self)
crates/frankclaw-core/src/auth.rs:39
↓ 17 callers
Method
complete
Try each provider in order with circuit breaker + retry. Providers that don't list the requested model are skipped to avoid unnecessary 404s (e.g. se
crates/frankclaw-models/src/failover.rs:76
↓ 17 callers
Method
current_config
Get current config snapshot (cheap Arc clone).
crates/frankclaw-gateway/src/state.rs:141
↓ 17 callers
Function
spawn_request
(parent_depth: u32)
crates/frankclaw-runtime/src/subagent.rs:387
↓ 16 callers
Method
record_failure
Record a transient failure. Non-transient errors should NOT be recorded (e.g., auth failures, context length exceeded, model not found).
crates/frankclaw-models/src/circuit_breaker.rs:115
↓ 16 callers
Function
scan_for_leaks
Scan text for credential leaks. Returns a `LeakScanResult` with all matches found. If any match has `LeakAction::Block`, `should_block` is `true`. If
crates/frankclaw-runtime/src/leak_detector.rs:61
↓ 16 callers
Function
simple_request
Builds a minimal [`CompletionRequest`] with a single user message.
crates/frankclaw-models/tests/common/mod.rs:58
↓ 15 callers
Function
build_test_state
( temp_dir: &Path, )
crates/frankclaw-gateway/src/methods.rs:1071
↓ 15 callers
Function
load_from_config
(config: &FrankClawConfig)
crates/frankclaw-channels/src/lib.rs:130
↓ 15 callers
Function
normalize_outbound_text
( text: &str, flavor: OutboundTextFlavor, )
crates/frankclaw-channels/src/outbound_text.rs:7
↓ 15 callers
Method
read
( &self, id: &MediaId, )
crates/frankclaw-media/src/store.rs:216
↓ 15 callers
Method
status_code
HTTP-like status code for protocol responses.
crates/frankclaw-core/src/error.rs:125
↓ 14 callers
Function
apply_stream_event
Process a single SSE data payload and return any stream deltas.
crates/frankclaw-models/src/openai_compat.rs:223
↓ 14 callers
Function
open_sessions
( state_dir: &std::path::Path, )
crates/frankclaw-cli/src/main.rs:1659
↓ 14 callers
Function
parse_markdown
Parse a markdown string into a `MarkdownIR`.
crates/frankclaw-runtime/src/markdown.rs:54
↓ 14 callers
Method
record_llm_call
Record a completed LLM call. Call this AFTER the LLM call completes.
crates/frankclaw-models/src/cost_guard.rs:142
↓ 14 callers
Method
select
Select the best available key using round-robin. Returns `None` if all keys are in cooldown.
crates/frankclaw-core/src/api_keys.rs:84
↓ 13 callers
Function
openai_base_url
Returns the OpenAI-compatible base URL. If `OPENAI_API_KEY` looks like an OpenRouter key (`sk-or-*`), use the OpenRouter endpoint automatically.
crates/frankclaw-models/tests/common/mod.rs:19
↓ 12 callers
Function
count_matches
(re: &Regex, text: &str)
crates/frankclaw-models/src/routing.rs:285
↓ 12 callers
Function
openai_key
Returns the OpenAI API key from `OPENAI_API_KEY`, if set and non-empty.
crates/frankclaw-models/tests/common/mod.rs:10
↓ 12 callers
Function
render
Replace `{key}` placeholders in a template with provided values. ``` use frankclaw_runtime::prompts::render; let result = render("Hello {name}, you a
crates/frankclaw-runtime/src/prompts.rs:39
↓ 12 callers
Function
test_session
(key: &str)
crates/frankclaw-sessions/src/store.rs:862
↓ 12 callers
Method
upsert
(&self, _entry: &SessionEntry)
crates/frankclaw-tools/src/lib.rs:294
↓ 11 callers
Method
append_transcript
(&self, key: &SessionKey, entry: &TranscriptEntry)
crates/frankclaw-sessions/src/store.rs:347
↓ 11 callers
Function
generate_token
Generate a cryptographically secure random token (256 bits, base64url encoded). Suitable for: gateway auth tokens, webhook secrets, pairing codes.
crates/frankclaw-crypto/src/token.rs:7
↓ 11 callers
Function
log_event
(action: &str, outcome: &str, details: Value)
crates/frankclaw-gateway/src/audit.rs:3
↓ 11 callers
Function
openai_model
Pick a model that works with the detected endpoint.
crates/frankclaw-models/tests/common/mod.rs:30
↓ 11 callers
Method
send
(&self, msg: OutboundMessage)
crates/frankclaw-channels/src/slack.rs:349
↓ 11 callers
Method
store
Store bytes as a media file, scanning for malware first if a scanner is configured. Returns metadata on success, or `MalwareDetected` if the file is f
crates/frankclaw-media/src/store.rs:73
↓ 10 callers
Function
build_request_body
Build an OpenAI-compatible chat completions request body.
crates/frankclaw-models/src/openai_compat.rs:8
↓ 10 callers
Function
build_test_state
( temp_dir: &Path, mut config: FrankClawConfig, channels: Arc<ChannelSet>, )
crates/frankclaw-gateway/src/server.rs:2102
↓ 10 callers
Function
extract_links
Extract unique HTTP(S) URLs from a message. - Strips markdown link syntax first (so `[click](url)` is ignored). - Deduplicates URLs. - Filters out SS
crates/frankclaw-core/src/links.rs:114
↓ 10 callers
Method
get_transcript
( &self, key: &SessionKey, limit: usize, before_seq: Option<u64>, )
crates/frankclaw-sessions/src/store.rs:388
↓ 10 callers
Function
make_keys
(n: usize)
crates/frankclaw-core/src/api_keys.rs:241
↓ 10 callers
Function
model_cost
Per-model cost lookup table for multi-provider LLM support. Returns (input_cost_per_token, output_cost_per_token) as f64 pairs. Ollama and other loca
crates/frankclaw-models/src/costs.rs:11
↓ 10 callers
Function
print_section
(title: &str, checks: &[CheckResult])
crates/frankclaw-cli/src/main.rs:2074
↓ 10 callers
Method
resolve_session_id
(&self, requested: Option<&str>, ctx: &ToolContext)
crates/frankclaw-tools/src/lib.rs:443
↓ 10 callers
Function
sanitize_for_prompt
Strip Unicode control characters that could be used for prompt injection. Removes: - Unicode category Cc (control chars) except \t, \n, \r (which are
crates/frankclaw-core/src/sanitize.rs:21
↓ 9 callers
Function
anthropic_key
Returns the Anthropic API key from `ANTHROPIC_API_KEY`, if set and non-empty.
crates/frankclaw-models/tests/common/mod.rs:41
↓ 9 callers
Method
append_transcript_entry
( &self, session_key: &SessionKey, seq: u64, role: Role, content: Stri
crates/frankclaw-runtime/src/lib.rs:1514
↓ 9 callers
Function
apply_stream_event
( state: &mut AnthropicStreamState, event_type: Option<&str>, data: &str, )
crates/frankclaw-models/src/anthropic.rs:384
↓ 9 callers
Function
build_runtime
( config: &frankclaw_core::config::FrankClawConfig, state_dir: &std::path::Path, sessions: std::sy
crates/frankclaw-cli/src/main.rs:4282
↓ 9 callers
Method
connect_page_socket
( &self, ws_url: &str, )
crates/frankclaw-tools/src/lib.rs:867
↓ 9 callers
Method
get_conn
(&self)
crates/frankclaw-sessions/src/store.rs:137
↓ 9 callers
Method
list
(&self)
crates/frankclaw-cron/src/service.rs:226
↓ 9 callers
Function
make_request
(method: Method, params: serde_json::Value)
crates/frankclaw-gateway/src/methods.rs:925
↓ 9 callers
Method
mark_stuck
Mark the job as stuck with a reason.
crates/frankclaw-cron/src/job.rs:190
↓ 9 callers
Function
resolve_channel_value
( account: &Value, inline_keys: &[&str], env_keys: &[&str], default_env: Option<&str>, cha
crates/frankclaw-channels/src/lib.rs:404
↓ 9 callers
Method
send
Send a JSON-RPC request and receive the response.
crates/frankclaw-tools/src/mcp/mod.rs:171
↓ 9 callers
Function
temp_store
Helper to create a temp store for tests.
crates/frankclaw-sessions/src/store.rs:851
↓ 8 callers
Method
attempt_recovery
Attempt recovery from stuck state. Returns `Err` if the job is not stuck or has exceeded max repair attempts.
crates/frankclaw-cron/src/job.rs:197
↓ 8 callers
Function
build_request_body
(request: &CompletionRequest)
crates/frankclaw-models/src/anthropic.rs:163
↓ 8 callers
Function
build_role_snapshot
Build a compact ARIA tree snapshot from CDP `Accessibility.getFullAXTree` nodes. Returns the indented tree text and a map of element references.
crates/frankclaw-tools/src/aria.rs:184
↓ 8 callers
Function
deliver_outbound_message
( channel: Arc<dyn ChannelPlugin>, outbound: OutboundMessage, media: Option<&MediaStore>, )
crates/frankclaw-gateway/src/delivery.rs:66
↓ 8 callers
Function
detect_command
Check if a message starts with a known command.
crates/frankclaw-runtime/src/commands.rs:157
↓ 8 callers
Function
encrypt
Encrypt plaintext with a 256-bit key using ChaCha20-Poly1305. Each call generates a fresh random nonce. The nonce is stored alongside the ciphertext
crates/frankclaw-crypto/src/encryption.rs:24
↓ 8 callers
Function
estimate_messages_tokens
Estimate total tokens for a slice of messages.
crates/frankclaw-runtime/src/context.rs:46
↓ 8 callers
Method
fire
Fire an event, running all matching handlers. Handlers for both the general type and specific type:action pair are run. Execution is fire-and-forget:
crates/frankclaw-core/src/hooks.rs:136
↓ 8 callers
Function
optimize_context
Optimize a message list to fit within the model's context window. Strategy: 1. If messages fit within budget, return as-is. 2. Otherwise, drop oldest
crates/frankclaw-runtime/src/context.rs:77
↓ 8 callers
Function
parse_receive_event
( event: &SignalSseEvent, configured_account: Option<&str>, )
crates/frankclaw-channels/src/signal.rs:360
↓ 8 callers
Method
send
(&self, msg: OutboundMessage)
crates/frankclaw-channels/src/discord.rs:285
↓ 8 callers
Method
send
(&self, msg: OutboundMessage)
crates/frankclaw-channels/src/telegram.rs:404
↓ 8 callers
Method
send
( &self, msg: OutboundMessage, )
crates/frankclaw-gateway/src/server.rs:2091
↓ 8 callers
Function
validate_channel_account_value_source
( channel: &ChannelConfig, channel_name: &str, inline_keys: &[&str], env_keys: &[&str], la
crates/frankclaw-core/src/config.rs:500
↓ 8 callers
Function
validate_navigation_url
Validate that a browser navigation URL is not targeting private/internal IPs. Uses the same SSRF blocklist as media fetches.
crates/frankclaw-tools/src/lib.rs:1820
↓ 8 callers
Method
wait_for_ready
( &self, socket: &mut tokio_tungstenite::WebSocketStream<tokio_tungstenite::MaybeTlsStream<tok
crates/frankclaw-tools/src/lib.rs:894
↓ 7 callers
Function
assess_exposure
(config: &frankclaw_core::config::FrankClawConfig)
crates/frankclaw-gateway/src/auth.rs:150
↓ 7 callers
Method
bot_auth_header
(&self)
crates/frankclaw-channels/src/slack.rs:54
↓ 7 callers
Function
build_media_group_items
( channel: &ChannelId, attachments: &[OutboundAttachment], text: &str, include_parse_mode: boo
crates/frankclaw-channels/src/telegram.rs:646
next →
1–100 of 2,115, ranked by callers