pub struct IngestArgs {Show 27 fields
pub dir: PathBuf,
pub type: MemoryType,
pub pattern: String,
pub recursive: bool,
pub enable_ner: bool,
pub auto_describe: bool,
pub no_auto_describe: bool,
pub skip_extraction: bool,
pub fail_fast: bool,
pub dry_run: bool,
pub max_files: usize,
pub namespace: Option<String>,
pub db: Option<String>,
pub format: JsonOutputFormat,
pub json: bool,
pub ingest_parallelism: Option<usize>,
pub low_memory: bool,
pub max_rss_mb: u64,
pub llm_parallelism: u64,
pub max_name_length: usize,
pub name_prefix: Option<String>,
pub mode: IngestMode,
pub max_cost_usd: Option<f64>,
pub wait_job_singleton: Option<u64>,
pub force_job_singleton: bool,
pub enrich_after: bool,
pub force_merge: bool,
}Expand description
Ingest args.
Fields§
§dir: PathBufDirectory containing files to ingest.
type: MemoryTypeMemory type stored in memories.type for every ingested file. Defaults to document.
pattern: StringGlob pattern matched against file basenames (default: *.md). Supports
*.<ext>, <prefix>*, and exact filename match.
recursive: boolRecurse into subdirectories.
enable_ner: boolEnable NER.
auto_describe: boolGAP-E2E-011: generates a heuristic description from the first meaningful
line of the body, instead of “ingested from <path>”. When
--no-auto-describe is passed, keeps the legacy behaviour.
no_auto_describe: boolNo auto describe.
skip_extraction: boolDeprecated: NER is now disabled by default. Kept for backwards compatibility.
fail_fast: boolStop on first per-file error instead of continuing with the next file.
dry_run: boolPreview file-to-name mapping without loading model or persisting.
max_files: usizeMaximum number of files to ingest (safety cap to prevent runaway ingestion).
namespace: Option<String>Namespace for the ingested memories.
db: Option<String>Database path. Falls back to XDG db.path, then graphrag.sqlite
under the XDG data directory.
format: JsonOutputFormatOutput format.
json: boolEmit machine-readable JSON on stdout.
ingest_parallelism: Option<usize>Number of files to extract+embed in parallel; default = max(1, cpus/2).min(4).
low_memory: boolForce single-threaded ingest to reduce RSS pressure.
Equivalent to --ingest-parallelism 1, takes precedence over any
explicit value. Recommended for environments with <4 GB available
RAM or container/cgroup constraints. Trade-off: 3-4x longer wall
time. Also available via XDG config set ingest.low_memory 1, which the
flag overrides. No environment variable supplies this value.
max_rss_mb: u64Maximum process RSS in MiB; abort if exceeded during embedding.
llm_parallelism: u64G42/S3 (v1.0.79): maximum simultaneous LLM embedding subprocesses PER FILE. Multiplies with –ingest-parallelism (files staged concurrently), hence the conservative default of 2. The effective value is further bounded by CPU count and available RAM.
max_name_length: usizeMaximum character length for derived memory names from file basenames.
Overrides the compile-time DERIVED_NAME_MAX_LEN constant (default 60).
Shorter values leave more headroom for collision suffix resolution.
name_prefix: Option<String>v1.1.1 (P12): kebab-case prefix prepended to every derived memory name,
AFTER the basename is normalized. Namespaces a corpus inside a shared
database (e.g. --name-prefix projx- yields projx-<derived>). The
derived part’s budget shrinks so the final name always respects the
80-char name cap. Only supported with --mode none.
mode: IngestModeExtraction mode: none (body-only, default).
max_cost_usd: Option<f64>Maximum cumulative cost in USD before aborting.
wait_job_singleton: Option<u64>G30: poll for the job singleton every second for up to N seconds when another invocation holds the lock. Default: 0 (fail fast).
force_job_singleton: boolG30: force acquisition of the singleton lock by removing a stale lock file from a previously crashed invocation.
enrich_after: boolv1.0.93 (GAP-OR-INGEST): run enrich --operation memory-bindings
after all files are embedded, using the active --llm-backend.
force_merge: boolGAP-SG-54: update existing memories instead of skipping them. Without
this flag a file whose derived name already exists is reported skipped;
with it the existing memory’s body, embedding and chunks are refreshed
(the remember --force-merge update path applied per file).
Trait Implementations§
Source§impl Args for IngestArgs
impl Args for IngestArgs
Source§fn augment_args<'b>(__clap_app: Command) -> Command
fn augment_args<'b>(__clap_app: Command) -> Command
Source§fn augment_args_for_update<'b>(__clap_app: Command) -> Command
fn augment_args_for_update<'b>(__clap_app: Command) -> Command
Command so it can instantiate self via
FromArgMatches::update_from_arg_matches_mut Read moreSource§impl FromArgMatches for IngestArgs
impl FromArgMatches for IngestArgs
Source§fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>
fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>
Source§fn from_arg_matches_mut(
__clap_arg_matches: &mut ArgMatches,
) -> Result<Self, Error>
fn from_arg_matches_mut( __clap_arg_matches: &mut ArgMatches, ) -> Result<Self, Error>
Source§fn update_from_arg_matches(
&mut self,
__clap_arg_matches: &ArgMatches,
) -> Result<(), Error>
fn update_from_arg_matches( &mut self, __clap_arg_matches: &ArgMatches, ) -> Result<(), Error>
ArgMatches to self.Source§fn update_from_arg_matches_mut(
&mut self,
__clap_arg_matches: &mut ArgMatches,
) -> Result<(), Error>
fn update_from_arg_matches_mut( &mut self, __clap_arg_matches: &mut ArgMatches, ) -> Result<(), Error>
ArgMatches to self.Auto Trait Implementations§
impl Freeze for IngestArgs
impl RefUnwindSafe for IngestArgs
impl Send for IngestArgs
impl Sync for IngestArgs
impl Unpin for IngestArgs
impl UnsafeUnpin for IngestArgs
impl UnwindSafe for IngestArgs
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<T> ErasedDestructor for Twhere
T: 'static,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more