Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/Alishahryar1/free-claude-code
/ functions
Functions
3,538 in github.com/Alishahryar1/free-claude-code
⨍
Functions
3,538
◇
Types & classes
344
↳
Endpoints
62
↓ 495 callers
Method
get
(self, url: str)
tests/api/test_admin.py:530
↓ 402 callers
Method
append
(self, text: str)
messaging/transcript/segments.py:56
↓ 150 callers
Method
get
Return an existing provider or create it lazily.
providers/runtime/cache.py:33
↓ 134 callers
Function
format_sse_event
Format one Anthropic-style SSE event.
core/anthropic/streaming/emitter.py:31
↓ 104 callers
Method
get
(self, key, default=None)
tests/providers/test_converter.py:29
↓ 80 callers
Method
_build_request_body
( self, request: Any, thinking_enabled: bool | None = None )
providers/zai/client.py:35
↓ 78 callers
Method
stream_response
( self, request: Any, input_tokens: int = 0, *, request_id: str | None
tests/providers/test_model_validation.py:340
↓ 73 callers
Method
json
(self)
tests/contracts/test_local_provider_smoke.py:17
↓ 72 callers
Method
apply
Apply a parsed CLI transcript event.
messaging/transcript/buffer.py:49
↓ 71 callers
Function
parse_sse_text
(text: str)
core/anthropic/stream_contracts.py:75
↓ 67 callers
Method
resolve
(self, claude_model_name: str)
api/model_router.py:44
↓ 53 callers
Function
create_app
Create and configure the FastAPI application.
api/app.py:87
↓ 50 callers
Function
trace_event
Emit one structured TRACE row (merged into JSON by the log sink).
core/trace.py:50
↓ 43 callers
Function
_make_incoming
Create a minimal IncomingMessage for testing.
tests/messaging/test_tree_concurrency.py:12
↓ 42 callers
Method
get_node
(self, node_id: str)
messaging/trees/runtime.py:62
↓ 41 callers
Method
get_tree_for_node
Get the tree containing a given node.
messaging/trees/manager.py:115
↓ 40 callers
Method
create_tree
Create a new tree with a root node. Args: node_id: ID for the root node incoming: The incoming message
messaging/trees/manager.py:40
↓ 37 callers
Function
parse_cli_event
Parse a CLI event and return a structured result. Args: event: Raw event dictionary from CLI log_raw_cli: When True, log ful
messaging/event_parser.py:12
↓ 36 callers
Method
get_instance
Get the singleton instance of the limiter. ``rate_limit`` and ``rate_window`` apply only when the singleton is first created. Call :m
messaging/limiter.py:36
↓ 34 callers
Function
_make_provider
Create a provider instance for testing.
tests/providers/test_streaming_errors.py:61
↓ 34 callers
Function
incoming_message_factory
()
tests/conftest.py:156
↓ 32 callers
Method
convert_messages
( messages: list[Any], *, reasoning_replay: ReasoningReplayMode = ReasoningReplayMode.
core/anthropic/conversion.py:152
↓ 31 callers
Function
_make_chunk
Create a mock streaming chunk.
tests/providers/test_streaming_errors.py:95
↓ 31 callers
Method
count
Count tokens for a request after applying configured model routing.
api/handlers/token_count.py:39
↓ 31 callers
Method
feed
Feed text and return safe text plus detected tool calls.
core/anthropic/tools.py:96
↓ 31 callers
Method
reset_instance
Reset singleton (for testing).
providers/rate_limit.py:150
↓ 30 callers
Method
add
( self, *, nodeid: str, outcome: str, duration_s: float, marke
smoke/lib/report.py:28
↓ 30 callers
Method
add_to_tree
Add a reply as a child node to an existing tree. Args: parent_node_id: ID of the parent message node_id: ID
messaging/trees/manager.py:71
↓ 27 callers
Method
add_node
( self, node_id: str, incoming: IncomingMessage, status_message_id: str,
messaging/trees/runtime.py:47
↓ 27 callers
Function
extract_command_prefix
Extract the command prefix for fast prefix detection. Parses a shell command safely, handling environment variables and command injection att
api/command_utils.py:25
↓ 27 callers
Function
get_block_attr
Get an attribute from a Pydantic model, lightweight object, or dict.
core/anthropic/content.py:6
↓ 27 callers
Method
handle_message
Main entry point for handling an incoming platform message.
messaging/workflow.py:111
↓ 26 callers
Function
_make_request
Create a mock request with all fields build_request_body needs.
tests/providers/test_streaming_errors.py:90
↓ 26 callers
Method
clear
(self)
messaging/session/message_log.py:73
↓ 25 callers
Method
update
Render transcript + optional status line and edit the platform message.
messaging/ui_updates.py:50
↓ 24 callers
Method
enqueue
(self, node_id: str)
messaging/trees/runtime.py:92
↓ 24 callers
Method
feed
Feed content and yield parsed chunks.
core/anthropic/thinking.py:42
↓ 24 callers
Function
get_token_count
Estimate token count for a request.
core/anthropic/tokens.py:19
↓ 24 callers
Method
render
(self, ctx: RenderCtx, *, limit_chars: int, status: str | None)
messaging/transcript/buffer.py:98
↓ 23 callers
Function
_parse_sse
Parse an SSE event string into its data payload.
tests/providers/test_stream_ledger.py:13
↓ 22 callers
Function
_local_client
(app)
tests/api/test_admin.py:15
↓ 22 callers
Function
extract_text_from_content
Extract concatenated text from message content.
core/anthropic/content.py:20
↓ 22 callers
Function
get_settings
Get cached settings instance.
config/settings.py:385
↓ 22 callers
Method
model_dump
(self, exclude_none=True)
tests/providers/test_ollama.py:38
↓ 22 callers
Function
optional_str
(value: Any)
core/openai_responses/tools.py:260
↓ 21 callers
Function
_collect_stream
Collect all SSE events from a stream.
tests/providers/test_streaming_errors.py:126
↓ 21 callers
Function
escape_md_v2
Escape text for Telegram MarkdownV2.
messaging/rendering/telegram_markdown.py:19
↓ 20 callers
Function
_set_home
(monkeypatch, tmp_path: Path)
tests/api/test_admin.py:19
↓ 20 callers
Method
flush
Flush any remaining tool call in the buffer.
core/anthropic/tools.py:188
↓ 20 callers
Method
save_tree_snapshot
(self, snapshot: TreeSnapshot)
messaging/session/store.py:93
↓ 19 callers
Method
load_conversation_snapshot
(self)
messaging/session/store.py:84
↓ 19 callers
Function
parse_provider_type
Extract provider type from any 'provider/model' string.
config/model_refs.py:26
↓ 18 callers
Function
_aiter
(chunks: list[str])
tests/core/openai_responses/test_sse.py:434
↓ 18 callers
Function
_make_tool_assembler
(provider: NvidiaNimProvider)
tests/providers/test_streaming_errors.py:72
↓ 18 callers
Function
_make_tree
Create a tree with a single root node.
tests/messaging/test_tree_concurrency.py:23
↓ 18 callers
Method
enqueue
Enqueue a node for processing. If the tree is not busy, processing starts immediately. If busy, the message is queued.
messaging/trees/manager.py:135
↓ 18 callers
Method
process_tool_call
Process a single tool-call delta and yield Anthropic SSE events.
providers/transports/openai_chat/tool_calls.py:98
↓ 18 callers
Method
stream
( self, payload: dict[str, Any], *, headers: dict[str, str] | None = None,
smoke/lib/e2e.py:114
↓ 17 callers
Function
_clear_process_config
(monkeypatch)
tests/api/test_admin.py:25
↓ 17 callers
Method
_is_thinking_enabled
Return whether thinking should be enabled for this request.
providers/base.py:40
↓ 17 callers
Function
_smoke_config
(**overrides)
tests/contracts/test_smoke_config.py:54
↓ 17 callers
Function
assert_anthropic_stream_contract
Check minimal Anthropic-style SSE invariants: start/stop, block nesting. Does *not* assert strict event ordering (e.g. :class:`message_delta` vs
core/anthropic/stream_contracts.py:97
↓ 17 callers
Function
make_outcome
Build one report outcome from a CLI run and its server log delta.
smoke/lib/claude_cli_matrix.py:334
↓ 17 callers
Function
map_error
Map OpenAI or HTTPX exception to specific ProviderError. Streaming transports should pass their scoped limiter (``self._global_rate_limiter``)
providers/error_mapping.py:257
↓ 17 callers
Method
run
(self)
smoke/lib/e2e.py:70
↓ 17 callers
Method
run
(self)
tests/cli/test_entrypoints.py:243
↓ 16 callers
Function
_count_text_tokens
(text: str)
core/anthropic/tokens.py:15
↓ 16 callers
Method
event
(self, event_type: str, data: dict[str, Any])
core/anthropic/streaming/emitter.py:42
↓ 16 callers
Function
format_native_sse_event
Format an SSE event from its event name and data payload.
core/anthropic/native_sse_block_policy.py:44
↓ 16 callers
Method
ingest_native_event
Record a native Anthropic SSE event and re-emit its normalized shape.
core/anthropic/streaming/ledger.py:405
↓ 16 callers
Method
update_state
( self, state: MessageState, *, session_id: str | None = None, error_m
messaging/trees/node.py:41
↓ 15 callers
Function
_ctx
()
tests/messaging/test_transcript.py:14
↓ 15 callers
Function
_settings
(**overrides)
tests/contracts/test_smoke_config.py:25
↓ 15 callers
Function
configure_logging
Configure loguru with JSON output to log_file and intercept stdlib logging. Idempotent: skips if already configured (e.g. hot reload). Use fo
config/logging_config.py:107
↓ 15 callers
Method
create
Create an Anthropic-compatible message response.
api/handlers/messages.py:65
↓ 15 callers
Method
emit_text_delta
(self, content: str)
core/anthropic/streaming/ledger.py:317
↓ 15 callers
Function
extract_managed_claude_session_id
Extract a Claude Code session ID from supported stream-json event shapes.
cli/managed/claude.py:191
↓ 15 callers
Function
format_response_sse_event
Format one OpenAI Responses SSE event.
core/openai_responses/events.py:16
↓ 15 callers
Method
message_delta
( self, stop_reason: str, output_tokens: int | None, *, usage_fields:
core/anthropic/streaming/ledger.py:210
↓ 15 callers
Function
parse_model_name
Extract model name from any 'provider/model' string.
config/model_refs.py:32
↓ 15 callers
Method
send
( self, text: str, *, message_id: str | None = None, reply_to: str | N
smoke/lib/e2e.py:524
↓ 14 callers
Function
_braced_body
(text: str, declaration: str)
tests/scripts/test_installers.py:16
↓ 14 callers
Function
_make_request
Create a MessagesRequest with a single user message.
tests/api/test_optimization_handlers.py:17
↓ 14 callers
Function
_repo_root
()
tests/scripts/test_ci_scripts.py:9
↓ 14 callers
Function
_repo_root
()
tests/scripts/test_uninstallers.py:10
↓ 14 callers
Method
emit_thinking_delta
(self, content: str)
core/anthropic/streaming/ledger.py:303
↓ 14 callers
Method
encode
( self, text: str, *, disallowed_special: tuple[str, ...] )
core/openai_responses/usage.py:11
↓ 14 callers
Method
process_node
Core task processor for a single CLI interaction.
messaging/node_runner.py:73
↓ 14 callers
Method
register_node
Register a node ID to a tree (for external mapping).
messaging/trees/manager.py:337
↓ 14 callers
Function
render_markdown_to_discord
Render common Markdown into Discord-compatible format.
messaging/rendering/discord_markdown.py:55
↓ 14 callers
Method
start_task
Start a new task or continue an existing session. Args: prompt: The user's message/prompt session_id: Option
cli/managed/session.py:91
↓ 14 callers
Method
to_anthropic_payload
(self, request: Mapping[str, Any])
core/openai_responses/adapter.py:20
↓ 13 callers
Function
_app_settings
Minimal settings namespace for AppRuntime (matches typed :class:`Settings` fields used).
tests/api/test_app_lifespan_and_errors.py:38
↓ 13 callers
Function
byId
(id)
api/admin_static/admin.js:34
↓ 13 callers
Method
content_block_delta
(self, index: int, delta_type: str, content: str)
core/anthropic/streaming/ledger.py:270
↓ 13 callers
Function
create_messaging_components
Create runtime/outbound components for the configured messaging platform.
messaging/platforms/factory.py:31
↓ 13 callers
Function
escape_discord
Escape text for Discord markdown (bold, italic, etc.).
messaging/rendering/discord_markdown.py:19
↓ 13 callers
Method
estimate_output_tokens
(self)
core/anthropic/streaming/ledger.py:589
↓ 13 callers
Function
format_exception_for_log
Return exception type and optionally ``str(exc)`` for operator diagnostics.
messaging/safe_diagnostics.py:6
↓ 13 callers
Function
get_user_facing_error_message
Return a readable, non-empty error message for users. Known transport and OpenAI SDK exception types are mapped to stable wording before fall
core/anthropic/errors.py:7
next →
1–100 of 3,538, ranked by callers