MCPcopy Create free account

hub / github.com/codag-megalith/codag-drain / functions

Functions240 in github.com/codag-megalith/codag-drain

↓ 82 callersMethodlen
(&self)
codag-drain/src/stream.rs:39
↓ 58 callersMethodpush
Ingest one line.
codag-drain/src/stream.rs:29
↓ 33 callersMethodas_str
(&self)
drain3_rust/src/cluster.rs:45
↓ 22 callersMethodadd_log_message
Ingest a raw log line. Returns the (possibly new) cluster the message was assigned to and a tag describing what changed.
drain3_rust/src/drain.rs:58
↓ 22 callersMethodis_empty
(&self)
codag-drain/src/stream.rs:43
↓ 15 callersFunctionauthed
(req: Request<Body>)
examples/server/tests/integration.rs:58
↓ 14 callersFunctiontemplate_logs
Template a batch of log lines.
codag-drain/src/compress.rs:279
↓ 14 callersFunctionv
(words: &[&str])
codag-drain/src/compress/template.rs:288
↓ 13 callersMethodinsert
Insert or update a cluster (touches LRU).
drain3_rust/src/storage.rs:27
↓ 12 callersFunctionmetric_values
(rows: &[Metrics], f: fn(Metrics) -> f64)
codag-drain/tests/eval_loghub.rs:382
↓ 11 callersMethodcontains
(&self, id: &usize)
drain3_rust/src/storage.rs:64
↓ 11 callersMethodlen
(&self)
drain3_rust/src/storage.rs:78
↓ 10 callersFunctionapp
()
examples/server/tests/integration.rs:40
↓ 9 callersFunctionbootstrap_mean_ci
(vals: &[f64])
codag-drain/tests/eval_loghub.rs:324
↓ 9 callersMethodget_mut
Get a mutable reference, **promoting** the entry in the LRU.
drain3_rust/src/storage.rs:47
↓ 8 callersFunctionbody_string
(resp: axum::response::Response)
examples/server/tests/integration.rs:35
↓ 8 callersFunctionerror
(status: StatusCode, msg: impl Into<String>)
examples/server/src/routes.rs:78
↓ 8 callersFunctionlex
Tokenize by generic character classes while preserving byte spans.
codag-drain/src/compress/lex.rs:35
↓ 8 callersFunctionpred_from_kind
(kind: GrouperKind, lines: &[LogLine])
codag-drain/tests/eval_loghub.rs:405
↓ 8 callersFunctions
(val: &str)
drain3_rust/src/tests.rs:4
↓ 7 callersMethodget_template
(&self)
drain3_rust/src/cluster.rs:20
↓ 7 callersMethodgroup
(&self, lines: &[LogLine])
codag-drain/src/compress/grouper.rs:114
↓ 7 callersFunctionparse_line
Heuristically parse one raw text line into a [`LogLine`]. The parser recognizes a leading ISO-like timestamp or epoch, then a level token among the n
codag-drain/src/input.rs:41
↓ 7 callersMethodrender
Render one compact text line per template group.
codag-drain/src/compress.rs:131
↓ 5 callersFunctiondefault_masking_instructions
Returns common masking patterns matching Python Drain3 defaults: - IP addresses - Hex sequences (0x...) - Numbers at word boundaries
drain3_rust/src/masking.rs:57
↓ 5 callersFunctionenv_usize
(name: &str, default: usize)
examples/server/src/session.rs:51
↓ 5 callersFunctionrouter
Build the application router.
examples/server/src/routes.rs:40
↓ 5 callersFunctionsample_text
()
examples/server/tests/integration.rs:19
↓ 5 callersMethodshutdown
Gracefully shut down the pipeline. Drops the sender (so the updater loop exits after processing remaining events) and awaits the updater task.
drain3_rust/src/pipeline.rs:87
↓ 5 callersFunctionto_lines
(contents: &[String])
codag-drain/tests/eval_loghub.rs:443
↓ 4 callersFunctionbootstrap_mean_delta_ci
(candidate: &[f64], baseline: &[f64])
codag-drain/tests/eval_loghub.rs:350
↓ 4 callersFunctionderive_multi_template
Multi-member derivation: a position is static iff *all* members share the same normalized token at that position (requires equal length). If members a
codag-drain/src/compress/template.rs:186
↓ 4 callersFunctionlines_of
(msgs: &[&str])
codag-drain/src/compress/grouper.rs:458
↓ 4 callersMethodmask
Apply all masking rules sequentially, returning the masked string.
drain3_rust/src/masking.rs:40
↓ 4 callersMethodmatch_default
Convenience wrapper - `match_log` with strategy `"never"`.
drain3_rust/src/drain.rs:136
↓ 4 callersFunctionparse_json_line
Parse one NDJSON line `{"message","level","timestamp"}`.
codag-drain/src/input.rs:89
↓ 4 callersFunctionsv
(vals: &[&str])
drain3_rust/src/tests.rs:8
↓ 4 callersMethodvalues
(&self)
drain3_rust/src/storage.rs:71
↓ 3 callersMethodadd_log_message_from_tokens
Ingest a pre-tokenized log line. Same as [`add_log_message`] but skips tokenization - useful when preprocessing has already been done (e.g. in the co
drain3_rust/src/drain.rs:71
↓ 3 callersFunctioncreate_template
Merge two equal-length token sequences into a template. Matching positions keep the shared token; mismatches become `param_str`.
drain3_rust/src/similarity.rs:44
↓ 3 callersMethodcreate_template_pub
Public template-creation helper (mainly for testing).
drain3_rust/src/drain.rs:151
↓ 3 callersFunctioncsv_path
(dir: &Path, system: &str)
codag-drain/tests/eval_loghub.rs:66
↓ 3 callersFunctionderive_pair_template
Returns a conservative wildcard template (space-joined, placeholders collapsed) from two normalized token lists, using `a_raw`'s tokens for the equal-
codag-drain/src/compress/template.rs:160
↓ 3 callersFunctionfinalize
Emit groups sorted by their smallest member index, members ascending.
codag-drain/src/compress/grouper.rs:62
↓ 3 callersFunctionget_opcodes
Compute alignment opcodes via classic LCS DP, then merge non-equal regions into single `Gap` blocks (so consecutive replace/insert/delete collapse).
codag-drain/src/compress/template.rs:73
↓ 3 callersFunctionis_anchor
(tok: &LexToken)
codag-drain/src/compress/lex.rs:83
↓ 3 callersFunctionlimit
()
codag-drain/tests/eval_loghub.rs:50
↓ 3 callersFunctionloghub_dir
()
codag-drain/tests/eval_loghub.rs:44
↓ 3 callersFunctionmake_drain_with_masking
()
drain3_rust/src/bench.rs:49
↓ 3 callersFunctionmake_grouper
Build a `Box<dyn Grouper>` from the config.
codag-drain/src/compress/grouper.rs:33
↓ 3 callersFunctionparsed_lines
()
examples/server/tests/integration.rs:31
↓ 3 callersMethodpeek
Peek at a cluster **without** promoting it in the LRU.
drain3_rust/src/storage.rs:39
↓ 3 callersFunctionpred_from_grouper
Run one of our deterministic groupers and derive per-group templates through the same `Profile` path used by `template_logs`.
codag-drain/tests/eval_loghub.rs:392
↓ 3 callersFunctionread_rows
Read up to `n` `(Content, EventTemplate)` rows from a LogHub-2.0 structured CSV. Streams the file so the multi-GB systems (HDFS, BGL) never fully load
codag-drain/tests/eval_loghub.rs:73
↓ 3 callersMethodset_masker
Set the log masker (applied before tokenization).
drain3_rust/src/drain.rs:165
↓ 3 callersFunctionsystems
()
codag-drain/tests/eval_loghub.rs:57
↓ 3 callersFunctiontoken_is_anchor
(tok: &LexToken)
codag-drain/src/compress/lex.rs:139
↓ 2 callersFunctioncollapse_placeholders
Port of `_collapse_placeholders`: drop a `<*>` that immediately follows another `<*>`.
codag-drain/src/compress/template.rs:37
↓ 2 callersFunctioncompute_metrics
Compute GA, FGA, FTA, purity for a set of predicted groups against the per-line oracle `EventTemplate` strings. - **GA (line-weighted Group Accuracy)
codag-drain/tests/eval_loghub.rs:230
↓ 2 callersFunctionconfig_from_query
(q: &TemplateQuery, limits: &Limits)
examples/server/src/routes.rs:122
↓ 2 callersFunctionderive_lex_template
Render a multi-member template from lexical tokens. Positions are static only when every member has the same token text at that position. Dynamic pos
codag-drain/src/compress/lex.rs:93
↓ 2 callersFunctiondrain_tokens
(line: &str, mode: DrainTokenMode, masker: &LogMasker)
codag-drain/src/compress/grouper.rs:157
↓ 2 callersFunctionf1
F1 over (correct / n_pred) precision and (correct / n_oracle) recall.
codag-drain/tests/eval_loghub.rs:303
↓ 2 callersMethodfast_match
Score every candidate cluster and return the best one above `sim_th`.
drain3_rust/src/drain.rs:237
↓ 2 callersMethodget_content_as_tokens
(&self, content: &str)
drain3_rust/src/drain.rs:174
↓ 2 callersFunctionget_seq_distance
Compute token-level similarity between a template (`seq1`) and a log message (`seq2`). Returns `(similarity, wildcard_count)` where similarity is the
drain3_rust/src/similarity.rs:8
↓ 2 callersFunctiongithub_jsonl
()
codag-drain/tests/eval_loghub.rs:103
↓ 2 callersFunctiongithub_limit
()
codag-drain/tests/eval_loghub.rs:109
↓ 2 callersFunctiongroup_count_from_kind
(kind: GrouperKind, lines: &[LogLine])
codag-drain/tests/eval_loghub.rs:447
↓ 2 callersFunctioniso_or_epoch_re
()
codag-drain/src/input.rs:12
↓ 2 callersFunctionlimited_app
(limits: Limits)
examples/server/tests/integration.rs:44
↓ 2 callersFunctionline
(msg: &str)
codag-drain/src/stream.rs:60
↓ 2 callersFunctionline
(msg: &str)
codag-drain/src/compress.rs:347
↓ 2 callersFunctionmedian
Median over the FULL slice (incl. duplicates). Sorts a copy. Even-length = mean of the two middle elements (Python `statistics.median`).
codag-drain/src/compress/profile.rs:61
↓ 2 callersFunctionnorm_ws
Whitespace-normalize a template string: collapse runs of whitespace to a single space, then trim. Used for FTA string comparison.
codag-drain/tests/eval_loghub.rs:205
↓ 2 callersFunctionnum_re
`NUM = re.compile(r"-?\d+(?:\.\d+)?")` - first numeric substring of a slot.
codag-drain/src/compress/profile.rs:22
↓ 2 callersFunctionparse_limited_body
( headers: &HeaderMap, body_format_query: Option<&str>, body: &Bytes, limits: &Limits, )
examples/server/src/routes.rs:167
↓ 2 callersFunctionpred_from_drain3
Run base drain3 over the lines: each line's returned `cluster.cluster_id` is the predicted group; the final per-cluster `get_template()` (last seen) i
codag-drain/tests/eval_loghub.rs:417
↓ 2 callersFunctionpushed
(lines: &[LogLine], cfg: &TemplaterConfig)
codag-drain/src/stream.rs:64
↓ 2 callersFunctionread_github_rows
Read GitHub LoRA held-out rows as `(log line, oracle template)` pairs.
codag-drain/tests/eval_loghub.rs:169
↓ 2 callersFunctionregex_from_placeholder
Port of `regex_from_placeholder`, returning a *compiled* anchored regex. `<*>` -> `(.*?)`, the rest escaped, commas stripped, anchored `^...$`. Return
codag-drain/src/compress/template.rs:232
↓ 2 callersFunctionstate_with_limits
(limits: Limits)
examples/server/tests/integration.rs:48
↓ 2 callersFunctionstrip_commas
(s: &str)
codag-drain/src/compress/template.rs:223
↓ 2 callersFunctiontemplate_token
(raw: &str, normalized: &str)
codag-drain/src/compress/template.rs:23
↓ 2 callersMethodtemplates_with
(&self, config: &TemplaterConfig)
codag-drain/src/stream.rs:51
↓ 2 callersFunctiontokenize
(line: &str)
codag-drain/src/compress/template.rs:31
↓ 2 callersMethodtree_search
Walk the prefix tree to find the best matching cluster.
drain3_rust/src/drain.rs:191
↓ 2 callersFunctionwants_json
(format: Option<&str>)
examples/server/src/routes.rs:139
↓ 2 callersFunctionwhitespace_tokens
(line: &str, masker: &LogMasker)
codag-drain/src/compress/grouper.rs:141
↓ 1 callersMethodadd_seq_to_prefix_tree
Insert a newly created cluster into the prefix tree.
drain3_rust/src/drain.rs:278
↓ 1 callersFunctionanchor_chars
(tokens: &[LexToken], static_mask: &[bool])
codag-drain/src/compress/lex.rs:130
↓ 1 callersFunctionanchor_count
Count non-punctuation static anchors in a token vector/template mask.
codag-drain/src/compress/lex.rs:122
↓ 1 callersFunctionanchor_weight
(tok: &LexToken, idf: &HashMap<String, f64>)
codag-drain/src/compress/grouper.rs:323
↓ 1 callersFunctionauth_token_from_env
()
examples/server/src/session.rs:111
↓ 1 callersFunctionbench_concurrent_parallel
(logs: &[String], concurrency: usize)
drain3_rust/src/bench.rs:66
↓ 1 callersFunctionbench_concurrent_sequential
(logs: &[String])
drain3_rust/src/bench.rs:96
↓ 1 callersFunctionbench_sync
(logs: &[String])
drain3_rust/src/bench.rs:55
↓ 1 callersFunctionbody_format
Decide the ingest body format: explicit `?body=text|ndjson`, else sniff the `Content-Type` header (`application/x-ndjson` / `application/json`), else
examples/server/src/routes.rs:148
↓ 1 callersFunctionbuild_samples
(lines: &[LogLine], group: &Group, cap: usize)
codag-drain/src/compress.rs:211
↓ 1 callersFunctionbuild_slot_summary
(profile: &Profile, g_idx: usize, si: usize, cap: usize)
codag-drain/src/compress.rs:225
next →1–100 of 240, ranked by callers