MCPcopy Create free account

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

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

↓ 4 callersMethodencode_image
(self, images: torch.Tensor)
phases/19-capstone-projects/62-vision-language-pretraining/code/main.py:163
↓ 4 callersMethodend_span
(self)
phases/14-agent-engineering/23-otel-genai-conventions/code/main.py:62
↓ 4 callersFunctionepsilon_greedy
(q_table, state, rng, epsilon)
phases/09-reinforcement-learning/10-multi-agent-rl/code/main.py:34
↓ 4 callersFunctionestimate_tokens
(text)
phases/11-llm-engineering/13-production-app/code/production_app.py:320
↓ 4 callersMethodexceeded
()
phases/19-capstone-projects/01-terminal-native-coding-agent/code/ts/src/plan.ts:48
↓ 4 callersMethodexecutor
(tool, args)
phases/19-capstone-projects/24-plan-execute-control-flow/code/tests/test_agent.py:52
↓ 4 callersFunctionexpand
(node: Node)
phases/14-agent-engineering/04-tree-of-thoughts-lats/code/main.py:50
↓ 4 callersFunctionfactorial
(n)
phases/01-math-foundations/06-probability-and-distributions/code/probability.py:7
↓ 4 callersFunctionfaithfulness
(claims: list[str], context_texts: list[str], judge: MockJudge)
phases/19-capstone-projects/68-rag-eval-precision-recall/code/main.py:150
↓ 4 callersFunctionfakeEmbed
(text: string, dim = 64)
phases/19-capstone-projects/02-rag-over-codebase/code/ts/src/index_store.ts:19
↓ 4 callersFunctionfakeLLMCall
( systemPrompt: string, userMessage: string )
phases/16-multi-agent-and-swarms/01-why-multi-agent/code/single_vs_multi.ts:26
↓ 4 callersFunctionfake_embed
(text: str)
phases/19-capstone-projects/12-video-understanding-pipeline/code/main.py:28
↓ 4 callersFunctionfake_tts
Pretend TTS: element-wise mix content with speaker.
phases/06-speech-and-audio/08-voice-cloning-conversion/code/main.py:32
↓ 4 callersFunctionfile_sha256
(path: Path)
phases/19-capstone-projects/47-checkpoint-save-resume/code/main.py:156
↓ 4 callersMethodfit
(self, X, y)
phases/02-ml-fundamentals/04-decision-trees/code/trees.py:235
↓ 4 callersMethodfit
(self, X, y)
phases/02-ml-fundamentals/01-what-is-machine-learning/code/ml_intro.py:9
↓ 4 callersFunctionfmt
(b)
phases/10-llms-from-scratch/04-pre-training-mini-gpt/code/main.py:320
↓ 4 callersFunctionfmt
site/build.js:558
↓ 4 callersFunctionfmtCost
(n: number)
phases/17-infrastructure-and-production/15-batch-apis/code/main.ts:235
↓ 4 callersFunctionfmt_hours
(h: float)
phases/15-autonomous-systems/01-long-horizon-agents/code/main.py:49
↓ 4 callersMethodforward
(self, inputs)
phases/03-deep-learning-core/02-multi-layer-networks/code/main.py:24
↓ 4 callersFunctionforward_d
(x, D)
phases/08-generative-ai/03-gans-generator-discriminator/code/main.py:49
↓ 4 callersFunctionforward_g
(z, G)
phases/08-generative-ai/03-gans-generator-discriminator/code/main.py:42
↓ 4 callersMethodfrom_json
(cls, text: str)
phases/19-capstone-projects/42-large-corpus-downloader/code/main.py:95
↓ 4 callersMethodfrom_predictions
(cls, confidences: Sequence[float], correct: Sequence[int], bins: int = 10)
phases/19-capstone-projects/73-perplexity-calibration/code/main.py:189
↓ 4 callersFunctionfx
(x)
site/lesson-figures.js:154
↓ 4 callersFunctiong_forward
(z, c, G, num_classes)
phases/08-generative-ai/04-conditional-gans-pix2pix/code/main.py:48
↓ 4 callersFunctiongateway_tools_call
(bearer: str, canonical_name: str, args: dict)
phases/13-tools-and-protocols/17-mcp-gateways-and-registries/code/main.py:128
↓ 4 callersFunctiongenerate_answer
(query: str, ranked: list[tuple[Chunk, float]])
phases/19-capstone-projects/69-end-to-end-rag-system/code/main.py:435
↓ 4 callersFunctiongenerate_classification_data
(n_samples=200, seed=42)
phases/02-ml-fundamentals/04-decision-trees/code/trees.py:286
↓ 4 callersFunctiongenerate_classification_data
(n_samples=200, n_classes=3, seed=42)
phases/02-ml-fundamentals/06-knn-and-distances/code/knn.py:183
↓ 4 callersFunctiongenerate_data
(n_samples=30, noise_std=0.5, x_range=(-3, 3), seed=None)
phases/02-ml-fundamentals/10-bias-variance/code/bias_variance.py:10
↓ 4 callersMethodget
(key: K)
phases/17-infrastructure-and-production/14-prompt-semantic-caching/code/main.ts:51
↓ 4 callersMethodget
(id: string)
phases/19-capstone-projects/12-video-understanding-pipeline/code/ts/src/jobs.ts:20
↓ 4 callersFunctiongetFixture
(id: string)
phases/19-capstone-projects/04-multimodal-document-qa/code/ts/src/fixtures.ts:52
↓ 4 callersFunctiongpipe_schedule
Return the GPipe schedule as a list of (cycle, stage, microbatch, phase). Phase is 'F' for forward, 'B' for backward, '.' for idle. Cycle is the
phases/19-capstone-projects/79-pipeline-parallel/code/main.py:50
↓ 4 callersFunctiongroup
(a)
phases/18-ethics-safety-alignment/21-fairness-criteria-group-individual-counterfactual/code/main.py:72
↓ 4 callersMethodhandle_request
(self, user_id, query, template_name="general_chat", variables=None)
phases/11-llm-engineering/13-production-app/code/production_app.py:430
↓ 4 callersFunctionhas_non_finite_grad
Return True if any gradient contains a NaN or Inf.
phases/19-capstone-projects/45-gradient-clipping-amp/code/main.py:76
↓ 4 callersFunctionhashed_embed
Hashed bag of tokens embedding, L2 normalised. Deterministic stdlib only.
phases/19-capstone-projects/50-hypothesis-generator/code/main.py:66
↓ 4 callersFunctionheadersFor
(body: string, opts: SignedOpts = {})
phases/19-capstone-projects/06-devops-troubleshooting-agent/code/ts/tests/server.test.ts:13
↓ 4 callersMethodhistogram
(self, name: str, help: str = "")
phases/19-capstone-projects/28-observability-otel-traces/code/main.py:268
↓ 4 callersFunctionhook
(module, inp, out)
phases/00-setup-and-tooling/12-debugging-and-profiling/code/debug_tools.py:47
↓ 4 callersFunctionhuman
(x)
site/figures-llms2.js:437
↓ 4 callersFunctionhybrid_search
(query, chunks, vector_embeddings, vocab, idf, bm25_index, top_k=5, retrieval_pool=15)
phases/11-llm-engineering/07-advanced-rag/code/main.py:126
↓ 4 callersMethodingest
(raw: unknown)
phases/19-capstone-projects/11-llm-observability-dashboard/code/ts/src/spans.ts:110
↓ 4 callersMethodinsert
(self, token_ids, kv_per_token)
phases/10-llms-from-scratch/12-inference-optimization/code/main.py:220
↓ 4 callersFunctioninterpret_cohens_d
(d)
phases/01-math-foundations/15-statistics-for-ml/code/statistics.py:291
↓ 4 callersFunctioniqr_detect
(X, factor=1.5)
phases/02-ml-fundamentals/16-anomaly-detection/code/anomaly_detection.py:14
↓ 4 callersFunctionis_positive_semidefinite_2d
(H)
phases/01-math-foundations/18-convex-optimization/code/convex.py:41
↓ 4 callersFunctionkl_divergence
(p, q, base=2)
phases/01-math-foundations/09-information-theory/code/information_theory.py:30
↓ 4 callersFunctionkmeans
(data, k, max_iterations=100, seed=42)
phases/02-ml-fundamentals/07-unsupervised-learning/code/clustering.py:9
↓ 4 callersFunctionkv_cache_bytes
(cfg: HybridConfig, ctx: int, bytes_per_elem: int)
phases/10-llms-from-scratch/21-jamba-hybrid-ssm-transformer/code/main.py:33
↓ 4 callersFunctionkv_cache_memory
(config, seq_len, dtype_bytes=2)
phases/10-llms-from-scratch/12-inference-optimization/code/main.py:335
↓ 4 callersFunctionlat
(b)
site/figures-infra.js:277
↓ 4 callersFunctionlaunchWorktree
(args: LaunchArgs)
phases/19-capstone-projects/10-multi-agent-software-team/code/ts/src/runtime.ts:77
↓ 4 callersFunctionlcs_length
(a: list[str], b: list[str])
phases/19-capstone-projects/71-classical-metrics/code/main.py:99
↓ 4 callersFunctionlerp
(a, b, t)
site/figures.js:49
↓ 4 callersMethodload
(self)
phases/14-agent-engineering/34-repo-memory-and-state/code/main.py:118
↓ 4 callersMethodload
(self)
phases/15-autonomous-systems/16-checkpoints-rollback/code/main.py:49
↓ 4 callersFunctionlog_prob
(table, given, key, smooth_denom, alpha)
phases/05-nlp-foundations-to-advanced/07-pos-tagging-parsing/code/main.py:48
↓ 4 callersFunctionlogits
(theta, x)
phases/09-reinforcement-learning/08-ppo/code/main.py:41
↓ 4 callersFunctionloss
(m, beta)
site/figures-agents-alignment.js:306
↓ 4 callersFunctionmake_anomaly_data
(n_normal=500, n_anomaly=25, n_features=2, seed=42)
phases/02-ml-fundamentals/16-anomaly-detection/code/anomaly_detection.py:135
↓ 4 callersFunctionmake_dataset
Returns (pairs, categories). Each pair has instruction, response.
phases/19-capstone-projects/39-instruction-tuning-sft/code/main.py:242
↓ 4 callersFunctionmake_features
(center, n, d, rng, scale=0.4)
phases/08-generative-ai/14-evaluation-fid-clip-score/code/main.py:98
↓ 4 callersFunctionmake_pretrained_to_local
Return the full pretrained->local name map for a model with `num_layers` blocks.
phases/19-capstone-projects/37-loading-pretrained-weights/code/main.py:182
↓ 4 callersFunctionmake_text_data
(n_samples=1000, n_features=200, seed=42)
phases/02-ml-fundamentals/14-naive-bayes/code/naive_bayes.py:103
↓ 4 callersFunctionmapping
(z, layers)
phases/08-generative-ai/05-stylegan/code/main.py:32
↓ 4 callersFunctionmat
(rows: int, cols: int)
phases/12-multimodal-ai/03-blip2-qformer-bridge/code/main.py:33
↓ 4 callersFunctionmat_mul
(a, b)
phases/01-math-foundations/03-matrix-transformations/code/transformations.py:47
↓ 4 callersFunctionmatmul
(W, x)
phases/08-generative-ai/03-gans-generator-discriminator/code/main.py:25
↓ 4 callersFunctionmatmul
(W, x)
phases/08-generative-ai/04-conditional-gans-pix2pix/code/main.py:25
↓ 4 callersFunctionmatmul_vec
(M: list[list[float]], v: list[float])
phases/12-multimodal-ai/03-blip2-qformer-bridge/code/main.py:37
↓ 4 callersFunctionmean
(xs)
phases/19-capstone-projects/17-personal-ai-tutor/code/main.py:205
↓ 4 callersFunctionmeaningful
(text: string)
phases/11-llm-engineering/12-guardrails/code/main.ts:219
↓ 4 callersFunctionmemory_calculator
( params_billions, precision_bytes=2, optimizer="adam", num_gpus=1, sharding="none", s
phases/10-llms-from-scratch/05-scaling-distributed/code/main.py:85
↓ 4 callersFunctionmse
(e: Expr, xs: list[float])
phases/15-autonomous-systems/03-alphaevolve-evolutionary-coding/code/main.py:98
↓ 4 callersMethodmse
(self, X, y)
phases/02-ml-fundamentals/11-ensemble-methods/code/ensembles.py:192
↓ 4 callersMethodneighbors
(self, node)
phases/01-math-foundations/21-graph-theory/code/graph_theory.py:16
↓ 4 callersFunctionneighbour_cosine_curve
Average cosine similarity between row p and row p+k for k in 1..max_offset. Returns a list of length max_offset.
phases/19-capstone-projects/32-token-positional-embeddings/code/main.py:169
↓ 4 callersMethodnew
(rng: random.Random)
phases/16-multi-agent-and-swarms/20-marl-maddpg-qmix-mappo/code/main.py:28
↓ 4 callersFunctionnew_span_id
Random 8-byte hex string. Matches W3C trace context span id.
phases/19-capstone-projects/28-observability-otel-traces/code/main.py:125
↓ 4 callersFunctionnormalize
(text)
phases/05-nlp-foundations-to-advanced/13-question-answering/code/main.py:9
↓ 4 callersFunctionnormalize
(s: str)
phases/19-capstone-projects/49-lm-eval-harness/code/main.py:149
↓ 4 callersFunctionnormalize
(v: list[float])
phases/12-multimodal-ai/02-clip-contrastive-pretraining/code/main.py:16
↓ 4 callersFunctionopBox
(x, label, sub)
site/figures.js:663
↓ 4 callersFunctionoptimize
(optimizer, func, grad_func, start, steps=5000)
phases/01-math-foundations/08-optimization/code/optimizers.py:75
↓ 4 callersFunctionp95
Sample 95th percentile via nearest-rank.
phases/19-capstone-projects/27-eval-harness-fixture-tasks/code/main.py:141
↓ 4 callersFunctionpearson_correlation
(x, y)
phases/01-math-foundations/15-statistics-for-ml/code/statistics.py:68
↓ 4 callersMethodper_tool
(self, name: str)
phases/19-capstone-projects/25-verification-gates-observation-budget/code/main.py:106
↓ 4 callersFunctionperplexity_heuristic
Toy PPL proxy: ratio of non-ASCII / non-alphanumeric chars to total.
phases/18-ethics-safety-alignment/14-ascii-art-visual-jailbreaks/code/main.py:64
↓ 4 callersFunctionpick_best_branch
Pick the branch with the highest mean reward among triggered branches. Ties break alphabetically by branch id (deterministic).
phases/19-capstone-projects/57-end-to-end-research-demo/code/main.py:123
↓ 4 callersMethodpick_strategy
(self, query: str)
phases/19-capstone-projects/69-end-to-end-rag-system/code/main.py:250
↓ 4 callersFunctionpipeline
( query: str, retriever: BiEncoder, reranker: CrossEncoder, top_n: int = 10, top_k: int =
phases/19-capstone-projects/66-reranker-cross-encoder/code/main.py:215
↓ 4 callersMethodplan
(self, task: str, state: set[str], depth: int = 0, max_depth: int = 12)
phases/14-agent-engineering/11-planning-htn-and-evolutionary/code/main.py:64
↓ 4 callersFunctionpolicy_probs
(theta, p_idx)
phases/09-reinforcement-learning/12-rl-for-games/code/main.py:21
↓ 4 callersFunctionprecision
(y_true, y_pred)
phases/02-ml-fundamentals/09-model-evaluation/code/evaluation.py:113
↓ 4 callersFunctionprecision_recall_f1
(tp: int, fp: int, fn: int)
phases/19-capstone-projects/38-classifier-finetuning/code/main.py:438
↓ 4 callersMethodpredict
(self, X)
phases/02-ml-fundamentals/02-linear-regression/code/linear_regression.py:258
← previousnext →801–900 of 8,347, ranked by callers