The configuration to analyze with.
The plugins to run, either already grouped by their PluginType or as a plain list.
Readonlyactivatedclass names of plugins that activated since the last reset; only filled when config.repl.showPlugins is set
Readonlybasethe configuration as given, i.e. before FlowrConfig.specializeConfig is applied
ReadonlydepsIdentified dependencies and their versions.
ReadonlyenvEnvironment information used during analysis.
ReadonlyfilesFiles to be analyzed and their loading order.
ReadonlygasResource-usage guard (gas).
Call ctx.gas.checkGas(key) at expensive analysis sites to obtain the current pressure level.
Returns GasLevel.Normal with zero overhead when gas is disabled for key.
ReadonlyincThe incremental context provides potential information for the next incremental analysis run
ReadonlymetaProject metadata such as name, version, and namespace.
Provides the analyzer associated with this context, if any.
This is usually set when the context is used within an analyzer instance.
Please note, that this may be undefined if the context is used standalone (e.g., during setup or in plugins that do not have access to the analyzer).
baseConfig specialized for the project ProjectKind, with any runtime applied on top (those win over both base and specialization).
The R version analysis assumes when resolving versioned (base-R) exports (see resolveAssumedRVersion).
Whether resolvedRVersion is a genuine signal (a config pin, project metadata, or engine detection) rather than the fallback default.
Where resolvedRVersion comes from, which decides what it says about the analyzed code.
The project kind the effective config is specialized for, plus the overrides it applies, or undefined when no specialization is in effect.
The versions a dependency can possibly have (delegates to FlowrAnalyzerDependenciesContext#inferredRange).
Get a read-only version of this context. This is useful if you want to pass the context to a place where you do not want it to be modified or just to reduce the available methods.
Classify the ProjectKind of the project (delegates to the cached FlowrAnalyzerFilesContext#projectKind).
Reset the context to its initial state, e.g., removing all files, dependencies, and loading orders.
Discards every updateConfig override made so far, reverting config back to baseConfig (specialized for the project kind).
Record the engine's auto-detected R version (used when solver.sigdb.assumedRVersion is "auto").
Apply a runtime FlowrConfig update. It is layered on top of the specialized config (so it wins over project-kind specialization) and never mutates the shared baseConfig. The analysis cache must be invalidated separately (see FlowrAnalyzer.updateConfig), as the results were computed under the old config.
Optional ReadonlyabstractInterpretation?: {Optional ReadonlydefaultEngine?: "r-shell" | "tree-sitter"The default engine to use. If undefined, an arbitrary one from engines is used.
Optional ReadonlydefaultPlugins?: (string | [(...)?, (...)?] | undefined)[]Optional Readonlyengines?: (Engines to use for interacting with R code (TreeSitterEngineConfig, RShellEngineConfig); empty means all available engines.
Optional Readonlygas?: {Resource-usage guard (gas) configuration; disabled by default (every feature factor 0), enable by setting a
feature's factor > 0. See FlowrGasConfig, ReadOnlyFlowrAnalyzerGasContext.
Optional ReadonlycountedCheckEvery?: numberHow many calls one accounting of an armed budget covers (default DefaultCountedCheckEvery). Trades how far
a run may overshoot a bound against what the guard costs per node: 1 counts exactly, larger counts coarsely.
Optional Readonlyfeatures?: { [key: ...]: ... }Per-feature sensitivity factors. Missing or 0 disables checking with zero overhead.
Optional ReadonlyheapProvider?: () => ...Custom heap statistics source (programmatic configs only), overriding the built-in v8/performance.memory detection. Return undefined to skip the memory check.
Optional Readonlythresholds?: { memory?: ...; steps?: ...; timeMs?: ...; vertices?: ...; [key: ...]: ... }Thresholds scaled by each feature factor before comparison, optionally bounded per feature (see GasThresholdSpec).
Optional Readonlymemory?: ...Heap-usage fraction thresholds (0-1, before factor scaling).
Optional Readonlysteps?: ...Processed-AST-node thresholds, counted rather than sampled. Only read by keys that arm a budget (i.e. GasFeatureKey.Dataflow); absent means unbounded.
Optional ReadonlytimeMs?: ...Elapsed analysis time thresholds in milliseconds (before factor scaling).
Optional Readonlyvertices?: ...Created-dataflow-vertex thresholds, counted like FlowrGasThresholds.steps.
Optional ReadonlyignoreLoadCalls?: booleanOptional ReadonlyignoreSourceCalls?: booleanOptional Readonlyincremental?: { alwaysIncremental?: boolean; parsing?: { activated?: ...; heuristics?: ... } }Optional ReadonlyinputSources?: {Teaches the InputSourcesQuery|input-sources analysis further frameworks; entries are added to what flowR knows already. Usually set per ProjectKind via specializeConfig. See InputClassifierConfig.
Optionalcmdline?: (...)[]Optionalconst?: (...)[]Optionaldconst?: (...)[]Optionalffi?: (...)[]Optionalfile?: (...)[]Optionalglob?: (...)[]Optionallang?: (...)[]OptionallinkedEntryPoints?: (...)[]Calls that hand a function to a framework, which then binds linkedObjects to its parameters by position.
OptionallinkedObjects?: (...)[]Objects provided by a framework rather than by the code itself, like shiny's input.
Optionalnarrowing?: (...)[]Functions whose result is bounded by one of their arguments (classified by that argument alone).
Optionalnet?: (...)[]Optionaloptions?: (...)[]Optionalparam?: (...)[]Optionalpure?: (...)[]Functions which are considered to be pure (i.e., deterministic, trusted, safe, idempotent on the lub of the input types)
Optionalrand?: (...)[]Optionalscope?: (...)[]Optionalsystem?: (...)[]Optionaltempfile?: (...)[]Optionalunknown?: (...)[]Optionaluser?: (...)[]Optional Readonlylinter?: { disabledRules?: (...)[] }Optional ReadonlylogLevel?: "debug" | "silly" | "trace" | "info" | "warn" | "error" | "fatal"Optional Readonlyproject?: {OptionalassumeImplicitEcho?: booleanWhether the top level's visible results count as an output (the print category); off by default for a ProjectKind.Package, whose top level runs at install time.
OptionalbasePackages?: (...)[]The packages considered part of R itself; if unset, flowR derives them (for the assumed R version) from the signature database via baseRPackages.
Optionalclassification?: {OptionalnotebookExtensions?: ...File extensions marking a notebook (default ipynb, rmd, rmarkdown, qmd, rnw).
OptionalshinyDescriptionTypes?: ...DESCRIPTION Type: values that mark a shiny app (default shiny, shiny-app, shinyapp).
OptionalshinyEntryFiles?: ...File names a shiny app is assembled from (default app.R, ui.R, server.R, global.R).
OptionalshinyUsagePattern?: ...Optionaldiscovery?: { full?: ...; ignore?: ...; perKind?: ... }OptionalfailOnInaccessiblePath?: booleanOptionalimplicitSources?: (...)[]OptionalresolveUnknownPathsOnDisk?: booleanOptionaluseProjectType?: ProjectKindOptional Readonlyrepl?: {OptionalautoUseFileProtocol?: booleanAutomatically use the file protocol for inputs that look like paths (default true)
OptionaldfProcessorHeat?: booleanOptionalhints?: booleanWhether to show dim inline hints (e.g. :help) on the empty prompt; automatically disabled on non-interactive terminals
Optionalplugins?: (...)[]OptionalqueryStats?: booleanWhether :query closes with the line stating how long the queries took (default true, :query* never prints it)
OptionalquickStats?: booleanOptionalshowPlugins?: booleanWhether :version grays out the plugins that did not activate during the last analysis (default false)
Optional Readonlysemantics?: { environment?: { overwriteBuiltIns?: ... } }Optional Readonlysolver?: {Optional ReadonlyassumeAttachedPackages?: (...)[]Optional ReadonlyevalStrings?: booleanOptional Readonlyinstrument?: { dataflowExtractors?: ... }OptionaldataflowExtractors?: ...Modify the dataflow processors used during analysis; keep every processor correctness requires present. May affect precision/performance arbitrarily -- prefer decorating existing processors over replacing them.
Optional ReadonlyresolveSource?: {Optional ReadonlyapplyReplacements?: ...Regex replacements to try against a sourced file's candidate name, tried in order alongside the original
name, e.g. { '.*\\.R$': 'main.R' } makes source("foo bar.R") also try main.R.
Optional ReadonlyassumeFilesExist?: ...Optional ReadonlydropPaths?: ...Optional ReadonlyignoreCapitalization?: ...Optional ReadonlyinferWorkingDirectory?: ...Optional ReadonlyrepeatedSourceLimit?: ...Optional ReadonlysearchPath?: ...Optional Readonlysigdb?: {Optional ReadonlyadditionalPaths?: ...Optional ReadonlyassumedRVersion?: ...R version assumed when resolving versioned (base-R) exports: a pin, or "auto" to detect the installed R
(falling back to DefaultAssumedRVersion if none, e.g. tree-sitter). See resolveAssumedRVersion.
Optional ReadonlyautoSync?: ...Optional ReadonlyblobCacheBudgetMb?: ...How many MiB of decoded package blobs every open bundle may hold together; a bigger budget re-reads and re-parses less, a smaller one keeps less in memory (default 16).
Optional ReadonlydownloadRepo?: ...Optional ReadonlyeagerlyLoad?: ...Optional ReadonlyeagerlyLoadExports?: ...Optional Readonlyenabled?: ...Optional ReadonlyinstalledLibrary?: ...Recovering a package no signature database knows (e.g. maptools) from its local install: DESCRIPTION
states the version, NAMESPACE the exports. Opt-in, since it reads outside the analyzed project.
Optional ReadonlylinkBaseR?: ...Eagerly attach base-R namespaces (from a signature database) so bare base calls resolve without library() (default false; changes every analysis; needs a base-R signature database).
Optional ReadonlylinkBaseRCalls?: ...Add a lightweight Reads edge from a bare base-R call to its signature-database function vertex (built-in:pkg:fn); base-R qualification stays edge-free unless this is on (default false; adds edges to every base call).
Optional ReadonlylinkDescriptionDependencies?: ...Eagerly attach the namespaces of the project's declared DESCRIPTION dependencies (Imports/Depends) so their exports resolve without an explicit library() (default false; changes every analysis; needs a signature database resolving the declared packages).
Optional ReadonlylinkPackageCalls?: ...Add a lightweight Reads edge from a resolved package call (pkg::fn/attached export) to its signature-database function vertex (default false).
Optional ReadonlyloadProjectDependencies?: ...Optional ReadonlyversionOverrides?: ...Force an exact version for specific packages (mapping a package name to a version), overriding both the project constraint and the versionSelection policy; a version missing from the database falls back with a warning (default {}).
Optional ReadonlyversionSelection?: ...Optional ReadonlywarmInBackground?: ...Decompress the hot shards (base + most-downloaded) in a background task on startup, so the first library() lookup is warm (default false; useful for long-running servers/REPLs, not one-shot runs).
Optionalslicer?: { autoExtend?: ...; threshold?: ... }Optional ReadonlytrackEnvironments?: booleanOptional ReadonlytransitiveSideEffectRounds?: numberOptional Readonlyvariables?: VariableResolveOptional ReadonlyversionManagement?: { linkedVersionGroups?: ... }Optional ReadonlyspecializeConfig?: {Overwrite (parts of) this configuration per ProjectKind; an entry may inherit another kind's
overwrite first (own keys win). Resolve with FlowrConfig.forKind.
Optionalnotebook?: {Optional ReadonlyabstractInterpretation?: ...Optional ReadonlydefaultEngine?: ...The default engine to use. If undefined, an arbitrary one from engines is used.
Optional ReadonlydefaultPlugins?: ...Optional Readonlyengines?: ...Engines to use for interacting with R code (TreeSitterEngineConfig, RShellEngineConfig); empty means all available engines.
Optional Readonlygas?: ...Resource-usage guard (gas) configuration; disabled by default (every feature factor 0), enable by setting a
feature's factor > 0. See FlowrGasConfig, ReadOnlyFlowrAnalyzerGasContext.
Optional ReadonlyignoreLoadCalls?: ...Optional ReadonlyignoreSourceCalls?: ...Optional Readonlyincremental?: ...Optional Readonlyinherit?: ...Optional ReadonlyinputSources?: ...Teaches the InputSourcesQuery|input-sources analysis further frameworks; entries are added to what flowR knows already. Usually set per ProjectKind via specializeConfig. See InputClassifierConfig.
Optional Readonlylinter?: ...Optional ReadonlylogLevel?: ...Optional Readonlyproject?: ...Optional Readonlyrepl?: ...Optional Readonlysemantics?: ...Optional Readonlysolver?: ...Optional ReadonlyspecializeConfig?: ...Overwrite (parts of) this configuration per ProjectKind; an entry may inherit another kind's
overwrite first (own keys win). Resolve with FlowrConfig.forKind.
Optionalpackage?: {Optional ReadonlyabstractInterpretation?: ...Optional ReadonlydefaultEngine?: ...The default engine to use. If undefined, an arbitrary one from engines is used.
Optional ReadonlydefaultPlugins?: ...Optional Readonlyengines?: ...Engines to use for interacting with R code (TreeSitterEngineConfig, RShellEngineConfig); empty means all available engines.
Optional Readonlygas?: ...Resource-usage guard (gas) configuration; disabled by default (every feature factor 0), enable by setting a
feature's factor > 0. See FlowrGasConfig, ReadOnlyFlowrAnalyzerGasContext.
Optional ReadonlyignoreLoadCalls?: ...Optional ReadonlyignoreSourceCalls?: ...Optional Readonlyincremental?: ...Optional Readonlyinherit?: ...Optional ReadonlyinputSources?: ...Teaches the InputSourcesQuery|input-sources analysis further frameworks; entries are added to what flowR knows already. Usually set per ProjectKind via specializeConfig. See InputClassifierConfig.
Optional Readonlylinter?: ...Optional ReadonlylogLevel?: ...Optional Readonlyproject?: ...Optional Readonlyrepl?: ...Optional Readonlysemantics?: ...Optional Readonlysolver?: ...Optional ReadonlyspecializeConfig?: ...Overwrite (parts of) this configuration per ProjectKind; an entry may inherit another kind's
overwrite first (own keys win). Resolve with FlowrConfig.forKind.
Optionalproject?: {Optional ReadonlyabstractInterpretation?: ...Optional ReadonlydefaultEngine?: ...The default engine to use. If undefined, an arbitrary one from engines is used.
Optional ReadonlydefaultPlugins?: ...Optional Readonlyengines?: ...Engines to use for interacting with R code (TreeSitterEngineConfig, RShellEngineConfig); empty means all available engines.
Optional Readonlygas?: ...Resource-usage guard (gas) configuration; disabled by default (every feature factor 0), enable by setting a
feature's factor > 0. See FlowrGasConfig, ReadOnlyFlowrAnalyzerGasContext.
Optional ReadonlyignoreLoadCalls?: ...Optional ReadonlyignoreSourceCalls?: ...Optional Readonlyincremental?: ...Optional Readonlyinherit?: ...Optional ReadonlyinputSources?: ...Teaches the InputSourcesQuery|input-sources analysis further frameworks; entries are added to what flowR knows already. Usually set per ProjectKind via specializeConfig. See InputClassifierConfig.
Optional Readonlylinter?: ...Optional ReadonlylogLevel?: ...Optional Readonlyproject?: ...Optional Readonlyrepl?: ...Optional Readonlysemantics?: ...Optional Readonlysolver?: ...Optional ReadonlyspecializeConfig?: ...Overwrite (parts of) this configuration per ProjectKind; an entry may inherit another kind's
overwrite first (own keys win). Resolve with FlowrConfig.forKind.
Optionalscript?: {Optional ReadonlyabstractInterpretation?: ...Optional ReadonlydefaultEngine?: ...The default engine to use. If undefined, an arbitrary one from engines is used.
Optional ReadonlydefaultPlugins?: ...Optional Readonlyengines?: ...Engines to use for interacting with R code (TreeSitterEngineConfig, RShellEngineConfig); empty means all available engines.
Optional Readonlygas?: ...Resource-usage guard (gas) configuration; disabled by default (every feature factor 0), enable by setting a
feature's factor > 0. See FlowrGasConfig, ReadOnlyFlowrAnalyzerGasContext.
Optional ReadonlyignoreLoadCalls?: ...Optional ReadonlyignoreSourceCalls?: ...Optional Readonlyincremental?: ...Optional Readonlyinherit?: ...Optional ReadonlyinputSources?: ...Teaches the InputSourcesQuery|input-sources analysis further frameworks; entries are added to what flowR knows already. Usually set per ProjectKind via specializeConfig. See InputClassifierConfig.
Optional Readonlylinter?: ...Optional ReadonlylogLevel?: ...Optional Readonlyproject?: ...Optional Readonlyrepl?: ...Optional Readonlysemantics?: ...Optional Readonlysolver?: ...Optional ReadonlyspecializeConfig?: ...Overwrite (parts of) this configuration per ProjectKind; an entry may inherit another kind's
overwrite first (own keys win). Resolve with FlowrConfig.forKind.
Optionalshiny-app?: {Optional ReadonlyabstractInterpretation?: ...Optional ReadonlydefaultEngine?: ...The default engine to use. If undefined, an arbitrary one from engines is used.
Optional ReadonlydefaultPlugins?: ...Optional Readonlyengines?: ...Engines to use for interacting with R code (TreeSitterEngineConfig, RShellEngineConfig); empty means all available engines.
Optional Readonlygas?: ...Resource-usage guard (gas) configuration; disabled by default (every feature factor 0), enable by setting a
feature's factor > 0. See FlowrGasConfig, ReadOnlyFlowrAnalyzerGasContext.
Optional ReadonlyignoreLoadCalls?: ...Optional ReadonlyignoreSourceCalls?: ...Optional Readonlyincremental?: ...Optional Readonlyinherit?: ...Optional ReadonlyinputSources?: ...Teaches the InputSourcesQuery|input-sources analysis further frameworks; entries are added to what flowR knows already. Usually set per ProjectKind via specializeConfig. See InputClassifierConfig.
Optional Readonlylinter?: ...Optional ReadonlylogLevel?: ...Optional Readonlyproject?: ...Optional Readonlyrepl?: ...Optional Readonlysemantics?: ...Optional Readonlysolver?: ...Optional ReadonlyspecializeConfig?: ...Overwrite (parts of) this configuration per ProjectKind; an entry may inherit another kind's
overwrite first (own keys win). Resolve with FlowrConfig.forKind.
Optionalunknown?: {Optional ReadonlyabstractInterpretation?: ...Optional ReadonlydefaultEngine?: ...The default engine to use. If undefined, an arbitrary one from engines is used.
Optional ReadonlydefaultPlugins?: ...Optional Readonlyengines?: ...Engines to use for interacting with R code (TreeSitterEngineConfig, RShellEngineConfig); empty means all available engines.
Optional Readonlygas?: ...Resource-usage guard (gas) configuration; disabled by default (every feature factor 0), enable by setting a
feature's factor > 0. See FlowrGasConfig, ReadOnlyFlowrAnalyzerGasContext.
Optional ReadonlyignoreLoadCalls?: ...Optional ReadonlyignoreSourceCalls?: ...Optional Readonlyincremental?: ...Optional Readonlyinherit?: ...Optional ReadonlyinputSources?: ...Teaches the InputSourcesQuery|input-sources analysis further frameworks; entries are added to what flowR knows already. Usually set per ProjectKind via specializeConfig. See InputClassifierConfig.
Optional Readonlylinter?: ...Optional ReadonlylogLevel?: ...Optional Readonlyproject?: ...Optional Readonlyrepl?: ...Optional Readonlysemantics?: ...Optional Readonlysolver?: ...Optional ReadonlyspecializeConfig?: ...Overwrite (parts of) this configuration per ProjectKind; an entry may inherit another kind's
overwrite first (own keys win). Resolve with FlowrConfig.forKind.
This summarizes the other context layers used by the FlowrAnalyzer. Have a look at the attributes and layers listed below (e.g., files and deps) to get an idea of the capabilities provided by this context. Besides these, this layer only orchestrates the different steps and layers, providing a collection of convenience methods. In general, you do not have to worry about these details, as the FlowrAnalyzerBuilder and FlowrAnalyzer take care of them.
To inspect, e.g., the loading order, you can do so via ReadOnlyFlowrAnalyzerLoadingOrderContext#getLoadingOrder|files.loadingOrder.getLoadingOrder. To get information on a specific library, use deps.getDependency. If you are just interested in inspecting the context, you can use ReadOnlyFlowrAnalyzerContext instead (e.g., via inspect).