MCPcopy Create free account

hub / github.com/rohitg00/ai-engineering-from-scratch / functions

Functions8,347 in github.com/rohitg00/ai-engineering-from-scratch

↓ 1 callersFunctionparallel_vote
(prompt: str, llm: Callable[[str], str], n: int = 5)
phases/14-agent-engineering/12-anthropic-workflow-patterns/code/main.py:54
↓ 1 callersFunctionparam_count
(vocab_size, d_model, n_layers, n_heads, ffn_expansion=2.67, block_size=128)
phases/07-transformers-deep-dive/14-build-a-transformer-capstone/code/main.py:58
↓ 1 callersFunctionparam_count_vit
Approximate ViT parameter count (patch embed + transformer + head).
phases/07-transformers-deep-dive/09-vision-transformers/code/main.py:90
↓ 1 callersFunctionparameter_breakdown
()
phases/10-llms-from-scratch/04-pre-training-mini-gpt/code/main.py:273
↓ 1 callersFunctionparameter_count
(model)
phases/04-computer-vision/15-real-time-edge/code/main.py:32
↓ 1 callersFunctionparaphrase_converter
(s: str)
phases/18-ethics-safety-alignment/16-red-team-tooling-garak-llamaguard-pyrit/code/main.py:86
↓ 1 callersFunctionparseFrontmatter
(text)
site/build.js:313
↓ 1 callersFunctionparseGlossary
(content)
site/build.js:272
↓ 1 callersFunctionparsePort
(argv: string[], defaultPort: number)
phases/19-capstone-projects/12-video-understanding-pipeline/code/ts/src/index.ts:75
↓ 1 callersFunctionparsePort
(argv: string[], defaultPort: number)
phases/19-capstone-projects/17-personal-ai-tutor/code/ts/src/index.ts:115
↓ 1 callersFunctionparsePort
(argv: string[], defaultPort: number)
phases/19-capstone-projects/16-github-issue-to-pr-agent/code/ts/src/index.ts:145
↓ 1 callersFunctionparseReadme
(content, roadmapStatuses)
site/build.js:64
↓ 1 callersFunctionparseRoadmap
(content)
site/build.js:31
↓ 1 callersFunctionparse_anthropic
(resp: dict)
phases/13-tools-and-protocols/02-function-calling-deep-dive/code/main.py:210
↓ 1 callersFunctionparse_args
(argv: list[str])
scripts/link_check.py:407
↓ 1 callersFunctionparse_args
()
phases/19-capstone-projects/47-checkpoint-save-resume/code/main.py:441
↓ 1 callersFunctionparse_args
()
phases/19-capstone-projects/48-distributed-fsdp-ddp/code/main.py:377
↓ 1 callersFunctionparse_args
()
phases/19-capstone-projects/49-lm-eval-harness/code/main.py:473
↓ 1 callersFunctionparse_args
()
phases/19-capstone-projects/46-gradient-accumulation/code/main.py:311
↓ 1 callersFunctionparse_args
()
phases/10-llms-from-scratch/25-speculative-decoding/code/main.py:186
↓ 1 callersFunctionparse_artifact
(path: Path)
scripts/build_catalog.py:128
↓ 1 callersFunctionparse_frontmatter
(text: str)
scripts/build_catalog.py:105
↓ 1 callersFunctionparse_frontmatter
Parse a YAML-subset frontmatter block at the top of a markdown string. Returns the parsed key/value mapping, or None when no frontmatter is prese
scripts/_lib.py:12
↓ 1 callersFunctionparse_frontmatter
(text: str)
phases/13-tools-and-protocols/22-skills-and-agent-sdks/code/main.py:93
↓ 1 callersFunctionparse_gemini
(resp: dict)
phases/13-tools-and-protocols/02-function-calling-deep-dive/code/main.py:218
↓ 1 callersFunctionparse_openai
(resp: dict)
phases/13-tools-and-protocols/02-function-calling-deep-dive/code/main.py:201
↓ 1 callersFunctionparse_request
Parse one JSON line. Returns (Request, None) on success or (None, error_dict). error_dict is a JSON-RPC error response ready to write out.
phases/19-capstone-projects/22-jsonrpc-stdio-transport/code/main.py:70
↓ 1 callersFunctionparse_rules
()
phases/14-agent-engineering/33-instructions-as-executable-constraints/code/main.py:76
↓ 1 callersFunctionparse_tool_call
Qwen2.5-VL emits JSON tool calls; parse with fallback.
phases/12-multimodal-ai/09-qwen-vl-family-dynamic-fps/code/main.py:92
↓ 1 callersMethodpassed
(self)
phases/19-capstone-projects/38-classifier-finetuning/code/main.py:507
↓ 1 callersFunctionpatch_embed_params
(cfg: ViTConfig)
phases/12-multimodal-ai/01-vision-transformer-patch-tokens/code/main.py:55
↓ 1 callersFunctionpatch_toy_image
Walk an 8x8 grayscale image through patch-tokenize with P=4. Grid is 2x2 → 4 tokens. Each patch is 4x4=16 pixels flat.
phases/12-multimodal-ai/01-vision-transformer-patch-tokens/code/main.py:106
↓ 1 callersFunctionpatchify
(image, patch_size)
phases/07-transformers-deep-dive/09-vision-transformers/code/main.py:17
↓ 1 callersMethodpath_length
(self, x, depth=0)
phases/02-ml-fundamentals/16-anomaly-detection/code/anomaly_detection.py:80
↓ 1 callersFunctionpatternsDemo
()
phases/17-infrastructure-and-production/16-model-routing/code/main.ts:415
↓ 1 callersFunctionper_category_em
( model: TinyGPT, tok: InstructionTokenizer, pairs: Sequence[Dict[str, str]], cats: Sequence[s
phases/19-capstone-projects/39-instruction-tuning-sft/code/main.py:590
↓ 1 callersFunctionper_class_report
(cm)
phases/04-computer-vision/04-image-classification/code/main.py:168
↓ 1 callersFunctionper_group_params
(net)
phases/04-computer-vision/03-cnns-lenet-to-resnet/code/main.py:123
↓ 1 callersFunctionperceiver_resampler
Variable patches -> fixed K latents via cross-attention.
phases/12-multimodal-ai/04-flamingo-gated-cross-attention/code/main.py:68
↓ 1 callersMethodpermit
(self, repo: str, estimated_cost: float)
phases/19-capstone-projects/16-github-issue-to-pr-agent/code/main.py:45
↓ 1 callersFunctionpermutation_invariance_check
()
phases/04-computer-vision/13-3d-vision-nerf/code/main.py:80
↓ 1 callersFunctionperpendiculars
(action)
phases/09-reinforcement-learning/02-dynamic-programming/code/main.py:20
↓ 1 callersFunctionperplexity
(log_probs)
phases/10-llms-from-scratch/10-evaluation/code/main.py:105
↓ 1 callersFunctionpersist_transfer
(txid: str, from_acct: str, to_acct: str, amount: int)
phases/15-autonomous-systems/16-checkpoints-rollback/code/main.py:24
↓ 1 callersFunctionperturb
(e: Expr)
phases/15-autonomous-systems/03-alphaevolve-evolutionary-coding/code/main.py:73
↓ 1 callersFunctionphonemize
(text)
phases/06-speech-and-audio/07-text-to-speech/code/main.py:53
↓ 1 callersMethodpick
(signals: RouteSignals, policy: RoutePolicy)
phases/17-infrastructure-and-production/16-model-routing/code/main.ts:154
↓ 1 callersFunctionpickNext
(cur)
site/figures.js:331
↓ 1 callersFunctionpick_engine
(hardware: str, scale: str, workload: str)
phases/17-infrastructure-and-production/28-self-hosted-serving-selection/code/main.py:9
↓ 1 callersFunctionpick_entry_file
(py_files: list[Path])
scripts/lesson_run.py:85
↓ 1 callersFunctionpin_ok
(tool_name: str, description: str)
phases/13-tools-and-protocols/23-capstone-tool-ecosystem/code/main.py:118
↓ 1 callersFunctionpkce_pair
()
phases/13-tools-and-protocols/16-mcp-security-oauth-2-1/code/main.py:98
↓ 1 callersFunctionplain_tail
(concurrency: int, n_tokens: int = 1000, seed: int = 5)
phases/17-infrastructure-and-production/05-eagle3-speculative-decoding/code/main.py:79
↓ 1 callersMethodplan
Decompose. Real lead uses an LLM; this splits by heuristic.
phases/16-multi-agent-and-swarms/05-supervisor-orchestrator-pattern/code/main.py:74
↓ 1 callersFunctionplan_copies
(target: Path, minimal: bool)
scripts/scaffold_workbench.py:73
↓ 1 callersMethodplan_for
(self, question: str)
phases/14-agent-engineering/02-rewoo-plan-and-execute/code/main.py:90
↓ 1 callersFunctionplan_multi_image
(budget: int)
phases/12-multimodal-ai/08-llava-onevision-single-multi-video/code/main.py:59
↓ 1 callersFunctionplan_single_image
(budget: int)
phases/12-multimodal-ai/08-llava-onevision-single-multi-video/code/main.py:41
↓ 1 callersFunctionplan_video
(budget: int)
phases/12-multimodal-ai/08-llava-onevision-single-multi-video/code/main.py:77
↓ 1 callersFunctionplanner
Produces a structured spec from a high-level wish.
phases/16-multi-agent-and-swarms/08-role-specialization/code/main.py:38
↓ 1 callersFunctionplay
(audio_chunks)
phases/06-speech-and-audio/12-voice-assistant-pipeline/code/main.py:64
↓ 1 callersFunctionplurality
(votes: list[Vote])
phases/16-multi-agent-and-swarms/14-consensus-and-bft/code/main.py:25
↓ 1 callersMethodpoints
(self, num_steps: int | None = None)
phases/19-capstone-projects/44-cosine-lr-warmup/code/main.py:80
↓ 1 callersFunctionpolicyEngineDemo
()
phases/17-infrastructure-and-production/20-shadow-canary-progressive/code/main.ts:282
↓ 1 callersFunctionpolicy_decide
(server: MCPServer, tool: str, token: Token, args: dict, now: float)
phases/19-capstone-projects/13-mcp-server-with-registry/code/main.py:85
↓ 1 callersFunctionpolicy_evaluation
(policy, gamma=0.99, tol=1e-6, max_iter=5000)
phases/09-reinforcement-learning/02-dynamic-programming/code/main.py:41
↓ 1 callersFunctionpolicy_iteration
(gamma=0.99, tol=1e-6)
phases/09-reinforcement-learning/02-dynamic-programming/code/main.py:68
↓ 1 callersFunctionpolynomial_features
(row, degree=2)
phases/02-ml-fundamentals/08-feature-engineering/code/features.py:39
↓ 1 callersFunctionpos_2d
2D sinusoidal: split d_model in half, encode row and col independently.
phases/07-transformers-deep-dive/09-vision-transformers/code/main.py:72
↓ 1 callersFunctionpos_embed_params
(cfg: ViTConfig)
phases/12-multimodal-ai/01-vision-transformer-patch-tokens/code/main.py:60
↓ 1 callersFunctionposthoc_vs_native_table
()
phases/12-multimodal-ai/10-internvl3-native-multimodal/code/main.py:60
↓ 1 callersFunctionpostprocess
(pred_tensor, anchors, stride, conf_threshold=0.25, iou_threshold=0.45)
phases/04-computer-vision/06-object-detection-yolo/code/main.py:155
↓ 1 callersFunctionpower_iteration
(M, num_iters=200, tol=1e-10)
phases/01-math-foundations/11-singular-value-decomposition/code/svd.py:4
↓ 1 callersFunctionppo_training
( policy_model, reference_model, reward_model, prompts, num_episodes=20, lr=1.5e-5,
phases/10-llms-from-scratch/07-rlhf/code/main.py:220
↓ 1 callersFunctionppo_update
(theta, w, buffer, advantages, returns, lr_a=0.05, lr_v=0.1, eps=0.2, epochs=4, batch=32, rng=None)
phases/09-reinforcement-learning/08-ppo/code/main.py:112
↓ 1 callersFunctionprecompute_schedule
(betas)
phases/04-computer-vision/10-image-generation-diffusion/code/main.py:13
↓ 1 callersMethodpredicate
(state)
phases/14-agent-engineering/13-langgraph-stateful-graphs/code/main.ts:53
↓ 1 callersMethodpredict
(self, document)
phases/01-math-foundations/07-bayes-theorem/code/bayes.py:48
↓ 1 callersMethodpredict
(self, X)
phases/02-ml-fundamentals/14-naive-bayes/code/naive_bayes.py:88
↓ 1 callersMethodpredict
(self, X)
phases/02-ml-fundamentals/02-linear-regression/code/linear_regression.py:83
↓ 1 callersMethodpredict
(self, X)
phases/02-ml-fundamentals/02-linear-regression/code/linear_regression.py:196
↓ 1 callersMethodpredict
(self, X)
phases/02-ml-fundamentals/13-ml-pipelines/code/pipeline.py:131
↓ 1 callersMethodpredict
(self, X)
phases/02-ml-fundamentals/01-what-is-machine-learning/code/ml_intro.py:15
↓ 1 callersMethodpredict
(self, X)
phases/02-ml-fundamentals/11-ensemble-methods/code/ensembles.py:85
↓ 1 callersMethodpredict
(self, X)
phases/02-ml-fundamentals/11-ensemble-methods/code/ensembles.py:186
↓ 1 callersMethodpredict
(self, X)
phases/02-ml-fundamentals/11-ensemble-methods/code/ensembles.py:212
↓ 1 callersMethodpredict
(self, X)
phases/02-ml-fundamentals/11-ensemble-methods/code/ensembles.py:265
↓ 1 callersFunctionpredict_mft
(tokens, word_best, default_tag)
phases/05-nlp-foundations-to-advanced/07-pos-tagging-parsing/code/main.py:27
↓ 1 callersFunctionpredict_nb
(doc, class_priors, class_word_probs)
phases/05-nlp-foundations-to-advanced/05-sentiment-analysis/code/main.py:55
↓ 1 callersFunctionpredict_nli
(premise, hypothesis)
phases/05-nlp-foundations-to-advanced/21-nli-textual-entailment/code/main.py:34
↓ 1 callersMethodpredict_proba
(self, document)
phases/01-math-foundations/07-bayes-theorem/code/bayes.py:63
↓ 1 callersMethodpredict_proba
(self, X)
phases/02-ml-fundamentals/14-naive-bayes/code/naive_bayes.py:33
↓ 1 callersMethodpredict_proba
(self, X)
phases/02-ml-fundamentals/14-naive-bayes/code/naive_bayes.py:92
↓ 1 callersMethodpredict_single
(self, x)
phases/02-ml-fundamentals/02-linear-regression/code/linear_regression.py:108
↓ 1 callersMethodpredict_single
(self, x)
phases/02-ml-fundamentals/02-linear-regression/code/linear_regression.py:255
↓ 1 callersMethodpredict_with_neighbors
(self, x)
phases/02-ml-fundamentals/06-knn-and-distances/code/knn.py:101
↓ 1 callersFunctionpreprocess
(text, pos_tagger=None)
phases/05-nlp-foundations-to-advanced/01-text-processing/code/main.py:48
↓ 1 callersFunctionpreprocess_imagenet
(rgb_uint8)
phases/04-computer-vision/01-image-fundamentals/code/main.py:80
↓ 1 callersFunctionpresidio_scrub
Simple PII scrub stand-in: redact emails and SSN-shaped tokens.
phases/19-capstone-projects/08-production-rag-chatbot/code/main.py:168
↓ 1 callersFunctionpretrain_quick
A short LM pretraining pass to give the body non-trivial weights.
phases/19-capstone-projects/38-classifier-finetuning/code/main.py:335
← previousnext →4,701–4,800 of 8,347, ranked by callers