ElixirScope.CompileTime.Orchestrator (elixir_scope v0.0.1)

Orchestrates compile-time AST instrumentation by generating detailed plans based on user requests and AI analysis.

This module:

  • Takes high-level instrumentation requests
  • Analyzes target modules using AI.CodeAnalyzer
  • Generates detailed AST transformation plans
  • Coordinates with the unified tracing system

Summary

Functions

Generates a plan for on-demand instrumentation of a specific function.

Generates an AST instrumentation plan for the given target and options.

Functions

generate_function_plan(module, function, arity, opts \\ %{})

Generates a plan for on-demand instrumentation of a specific function.

generate_plan(target, opts \\ %{})

Generates an AST instrumentation plan for the given target and options.

Examples

# Basic function instrumentation
plan = generate_plan(MyModule, %{functions: [:my_func]})

# Granular variable capture
plan = generate_plan(MyModule, %{
  functions: [:complex_calc],
  capture_locals: [:temp1, :temp2, :result],
  after_line: 42
})

# Expression tracing
plan = generate_plan(MyModule, %{
  functions: [:algorithm],
  trace_expressions: [:process_item, :calculate_result]
})