lsp
The lsp namespace — 64 functions.
globals/lsp/check
lsp.check(path: string, opts: CheckOpts?) -> DiagnosticsResult
Validate a single .luau file in the VFS and return its
diagnostics. A path the check could not read comes back as one
lsp-check-* error naming the path and the reason, so errors == 0
means a code body was read and is clean.
Parameters
pathstring— VFS path.optsCheckOpts(optional) —{ severity?, limit?, context? }.
Returns DiagnosticsResult — Array of diagnostic tables.
local diags = lsp.check("/zero/source/main.luau")
globals/lsp/checkAll
lsp.checkAll(opts: CheckAllOpts?) -> CheckAllResult
Validate the user's Luau scripts and return an aggregate
summary plus diagnostic list. opts.scope = "user" (default)
skips library mounts; "all" includes them. The sweep is
time-budgeted (ZERO_EXECUTE_INLINE_BUDGET_MS, ~20s by default): if
the budget elapses it returns the partial result gathered so far
with budgetExceeded = true rather than blocking the engine.
Parameters
optsCheckAllOpts(optional) —{ scope?, severity?, limit? }.
Returns CheckAllResult — { filesChecked, errors, warnings, info, hints, budgetExceeded, diagnostics }.
globals/lsp/checkCode
lsp.checkCode(source: string, opts: CheckOpts?) -> DiagnosticsResult
Validate inline Luau source without a backing file. Useful for checking code before writing it to disk.
Parameters
sourcestring— Luau source.optsCheckOpts(optional) —{ severity?, limit?, context? }.
Returns DiagnosticsResult — Array of diagnostic tables.
globals/lsp/checkDirty
lsp.checkDirty() -> DiagnosticsResult
Drain the dirty-file set populated by the hot-reload hook, validate each, and return the combined diagnostic list.
Returns DiagnosticsResult — Array of diagnostic tables.
globals/lsp/describe
lsp.describe(path: string, opts: DescribeOpts?) -> DocEntry?
Inspect a single documented entry. Returns the full doc
table (signature, args, returns, examples, level), or nil.
The path is resolved independently of which root the doc is
registered under and of separator style, so the spelling that reads
off the API surface (renderer.texture.create) finds the entry
registered as globals/renderer/texture/create. A path naming a
binding the engine registered internally answers with the entry a Luau
module publishes over it where there is one, so the signature is the
call content makes; opts.includeInternal answers with the internally
registered entry itself. When a path does not resolve,
lsp.describePaths says what the registry holds near it.
Parameters
pathstring— Doc path (e.g."asset/resolve","renderer.texture.create").optsDescribeOpts(optional) — Optional{ includeInternal? }— default prefers the published entry.
Returns DocEntry? — Full doc table or nil.
local doc = lsp.describe("renderer.texture.create")
globals/lsp/describePaths
lsp.describePaths(path: string) -> { string }
List the registered doc paths related to path. A path that names
an entry returns every root it is registered under (the first is what
lsp.describe resolves to); a path that names a namespace returns the
entries registered under it. Empty when the registry holds nothing
near the path — so a lookup that returns nil can always be turned into
the list of what does exist.
Parameters
pathstring— Doc path in any spelling ("renderer.texture","ecs/query").
Returns { string } — Array of registered doc paths, most canonical first.
for _, p in ipairs(lsp.describePaths("renderer.texture")) do print(p) end
globals/lsp/describeTool
lsp.describeTool(path: string) -> string?
Return the full documentation text for a code-mode tool.
Parameters
pathstring— Tool path (e.g."scene/spawnLight").
Returns string? — Full tool docs or nil.
globals/lsp/docsByKind
lsp.docsByKind(kind: string) -> { MethodSummary }
List every doc whose registration kind matches kind.
Valid: "binding", "runtime_tool", "module", "component",
"library", "lua_export".
Parameters
kindstring— Registration kind.
Returns { MethodSummary } — Array of doc summary tables.
globals/lsp/getStrictMode
lsp.getStrictMode() -> StrictMode
Return the current strict mode.
Returns StrictMode — "off" | "soft" | "strict".
globals/lsp/isStrict
lsp.isStrict() -> boolean
Is the pre-execute LSP gate fully strict? False when off or in soft mode.
Returns boolean — True when fully strict.
globals/lsp/lastCheckGen
lsp.lastCheckGen() -> number
Generation counter — bumped each time the cache is rebuilt. UI polls this to know when to redraw.
Returns number — Generation number.
globals/lsp/methods
lsp.methods(namespace: string, opts: MethodsOpts?) -> { MethodSummary } | { string }
List every documented method / entry under a namespace. A broad
namespace (ui, renderer) returns a large dump by default, so two
options narrow it: opts.filter keeps only methods whose name (or
doc path) contains the substring, case-insensitively; opts.namesOnly
returns a plain list of method-name strings instead of the full
per-method summary tables — much smaller, and nothing to unwrap. The
listing answers with the surface content calls: an entry registered
internally is left out where its signature spells the __ binding or a
Luau module publishes the same member, and opts.includeInternal lists
every registered entry instead.
Parameters
namespacestring— Namespace name (e.g."entity","modules/Transform").optsMethodsOpts(optional) — Optional{ filter?, namesOnly?, includeInternal? }.
Returns { MethodSummary } | { string } — Array of method summary tables, or plain name strings when namesOnly is set (empty when the namespace is unknown or nothing matches the filter).
for _, name in ipairs(lsp.methods("ui", { namesOnly = true })) do print(name) end
lsp.methods("renderer", { filter = "shadow" })
globals/lsp/modules
lsp.modules() -> { ModuleEntry }
List every Luau library module the engine currently knows
about — discovered via --!module headers, library scans, and
manually-recorded docs.
Returns { ModuleEntry } — Array of module summary tables.
globals/lsp/namespaces
lsp.namespaces(opts: NamespacesOpts?) -> { NamespaceEntry }
List the documentation namespaces reachable from Luau. By
default only namespaces exposing at least one PUBLIC method are
returned, so the list matches what you can actually call — internal
FFI plumbing (e.g. pause, native_entity), whose public surface
lives elsewhere (engine.paused, the entity proxy, …), is left
out. Pass { includeInternal = true } to list every namespace,
internal ones included.
Parameters
optsNamespacesOpts(optional) — Optional{ includeInternal? }— default lists public only.
Returns { NamespaceEntry } — Array of namespace summary tables.
for _, ns in ipairs(lsp.namespaces()) do print(ns.name) end
globals/lsp/readDirectives
lsp.readDirectives(source: string) -> DirectiveBlock
Parse the leading --! directive block of a Luau source
string. Used by UIs that audit which files have skip directives
and what they suppress.
Parameters
sourcestring— Luau source text.
Returns DirectiveBlock — { mode, codes? }.
globals/lsp/search
lsp.search(query: string, opts: SearchOpts?) -> { MethodSummary }
Case-insensitive substring search across every registered
doc's path, signature, and description. Hits answer with the surface
content calls: an entry registered internally is left out where its
signature spells the __ binding or a Luau module publishes the same
member, and opts.includeInternal searches every registered entry.
Parameters
querystring— Substring to search for.optsSearchOpts(optional) —{ limit? = 50, includeInternal? }.
Returns { MethodSummary } — Array of method summary tables.
globals/lsp/setStrict
lsp.setStrict(enabled: boolean) -> boolean
Toggle the pre-execute LSP gate. Returns true when the change
was persisted to .world_settings, false when the play-mode write
lock blocked the write.
Parameters
enabledboolean— True = strict, false = off.
Returns boolean — Persistence signal.
globals/lsp/setStrictMode
lsp.setStrictMode(mode: StrictMode) -> boolean
Set the pre-execute strict gate's mode. Returns true when the
change was persisted to .world_settings, false when the
play-mode write lock blocked the write.
Parameters
modeStrictMode—"off"|"soft"|"strict".
Returns boolean — Persistence signal.
globals/lsp/summary
lsp.summary() -> Summary
Counts only — does not re-run validation.
Returns Summary — Counts of cached diagnostics by severity.
globals/lsp/tools
lsp.tools() -> { ToolEntry }
List every code-mode tool registered in the VFS under
/zero/docs/tools/<category>/<tool>.
Returns { ToolEntry } — Array of tool summary tables.
globals/lsp/typeOf
lsp.typeOf(expr_source: string, context_path: string?) -> TypeDescriptor
Infer the static type of a Luau expression. When
context_path is given, the file is loaded and walked so the
inference env contains every local + alias in scope at its end.
Parameters
expr_sourcestring— Luau expression source (no surrounding chunk).context_pathstring(optional) — VFS path whose scope should be visible.
Returns TypeDescriptor — Type descriptor table.
local td = lsp.typeOf("Transform.lookAt", "/zero/source/main.luau")
modules/lsp/README
require("@builtin/modules/api/engine/lsp") -- lsp (also available as global 'lsp')
Embedded Luau language server — check / search / inspect Public Luau surface over the __lsp Internal FFI namespace.
Usage: local lsp = require("@builtin/modules/api/engine/lsp") Also available as global: lsp
modules/lsp/check
check(path: string, opts: CheckOpts?): DiagnosticsResult
Validate a single .luau file in the VFS and return its
diagnostics. A path the check could not read comes back as one
lsp-check-* error naming the path and the reason, so errors == 0
means a code body was read and is clean.
Parameters
pathstring— VFS path.optsCheckOpts?(optional) —{ severity?, limit?, context? }.
local diags = lsp.check("/zero/source/main.luau")
modules/lsp/checkAll
checkAll(opts: CheckAllOpts?): CheckAllResult
Validate the user's Luau scripts and return an aggregate
summary plus diagnostic list. opts.scope = "user" (default)
skips library mounts; "all" includes them. The sweep is
time-budgeted (ZERO_EXECUTE_INLINE_BUDGET_MS, ~20s by default): if
the budget elapses it returns the partial result gathered so far
with budgetExceeded = true rather than blocking the engine.
Parameters
optsCheckAllOpts?(optional) —{ scope?, severity?, limit? }.
modules/lsp/checkCode
checkCode(source: string, opts: CheckOpts?): DiagnosticsResult
Validate inline Luau source without a backing file. Useful for checking code before writing it to disk.
Parameters
sourcestring— Luau source.optsCheckOpts?(optional) —{ severity?, limit?, context? }.
modules/lsp/checkDirty
checkDirty(): DiagnosticsResult
Drain the dirty-file set populated by the hot-reload hook, validate each, and return the combined diagnostic list.
modules/lsp/describe
describe(path: string, opts: DescribeOpts?): DocEntry?
Inspect a single documented entry. Returns the full doc
table (signature, args, returns, examples, level), or nil.
The path is resolved independently of which root the doc is
registered under and of separator style, so the spelling that reads
off the API surface (renderer.texture.create) finds the entry
registered as globals/renderer/texture/create. A path naming a
binding the engine registered internally answers with the entry a Luau
module publishes over it where there is one, so the signature is the
call content makes; opts.includeInternal answers with the internally
registered entry itself. When a path does not resolve,
lsp.describePaths says what the registry holds near it.
Parameters
pathstring— Doc path (e.g."asset/resolve","renderer.texture.create").optsDescribeOpts?(optional) — Optional{ includeInternal? }— default prefers the published entry.
local doc = lsp.describe("renderer.texture.create")
modules/lsp/describePaths
describePaths(path: string): { string }
List the registered doc paths related to path. A path that names
an entry returns every root it is registered under (the first is what
lsp.describe resolves to); a path that names a namespace returns the
entries registered under it. Empty when the registry holds nothing
near the path — so a lookup that returns nil can always be turned into
the list of what does exist.
Parameters
pathstring— Doc path in any spelling ("renderer.texture","ecs/query").
for _, p in ipairs(lsp.describePaths("renderer.texture")) do print(p) end
modules/lsp/describeTool
describeTool(path: string): string?
Return the full documentation text for a code-mode tool.
Parameters
pathstring— Tool path (e.g."scene/spawnLight").
modules/lsp/docsByKind
docsByKind(kind: string): { MethodSummary }
List every doc whose registration kind matches kind.
Valid: "binding", "runtime_tool", "module", "component",
"library", "lua_export".
Parameters
kindstring— Registration kind.
modules/lsp/getStrictMode
getStrictMode(): StrictMode
Return the current strict mode.
modules/lsp/isStrict
isStrict(): boolean
Is the pre-execute LSP gate fully strict? False when off or in soft mode.
modules/lsp/lastCheckGen
lastCheckGen(): number
Generation counter — bumped each time the cache is rebuilt. UI polls this to know when to redraw.
modules/lsp/methods
methods(namespace: string, opts: MethodsOpts?): { MethodSummary } | { string }
List every documented method / entry under a namespace. A broad
namespace (ui, renderer) returns a large dump by default, so two
options narrow it: opts.filter keeps only methods whose name (or
doc path) contains the substring, case-insensitively; opts.namesOnly
returns a plain list of method-name strings instead of the full
per-method summary tables — much smaller, and nothing to unwrap. The
listing answers with the surface content calls: an entry registered
internally is left out where its signature spells the __ binding or a
Luau module publishes the same member, and opts.includeInternal lists
every registered entry instead.
Parameters
namespacestring— Namespace name (e.g."entity","modules/Transform").optsMethodsOpts?(optional) — Optional{ filter?, namesOnly?, includeInternal? }.
for _, name in ipairs(lsp.methods("ui", { namesOnly = true })) do print(name) end
lsp.methods("renderer", { filter = "shadow" })
modules/lsp/modules
modules(): { ModuleEntry }
List every Luau library module the engine currently knows
about — discovered via --!module headers, library scans, and
manually-recorded docs.
modules/lsp/namespaces
namespaces(opts: NamespacesOpts?): { NamespaceEntry }
List the documentation namespaces reachable from Luau. By
default only namespaces exposing at least one PUBLIC method are
returned, so the list matches what you can actually call — internal
FFI plumbing (e.g. pause, native_entity), whose public surface
lives elsewhere (engine.paused, the entity proxy, …), is left
out. Pass { includeInternal = true } to list every namespace,
internal ones included.
Parameters
optsNamespacesOpts?(optional) — Optional{ includeInternal? }— default lists public only.
for _, ns in ipairs(lsp.namespaces()) do print(ns.name) end
modules/lsp/readDirectives
readDirectives(source: string): DirectiveBlock
Parse the leading --! directive block of a Luau source
string. Used by UIs that audit which files have skip directives
and what they suppress.
Parameters
sourcestring— Luau source text.
modules/lsp/search
search(query: string, opts: SearchOpts?): { MethodSummary }
Case-insensitive substring search across every registered
doc's path, signature, and description. Hits answer with the surface
content calls: an entry registered internally is left out where its
signature spells the __ binding or a Luau module publishes the same
member, and opts.includeInternal searches every registered entry.
Parameters
querystring— Substring to search for.optsSearchOpts?(optional) —{ limit? = 50, includeInternal? }.
modules/lsp/setStrict
setStrict(enabled: boolean): boolean
Toggle the pre-execute LSP gate. Returns true when the change
was persisted to .world_settings, false when the play-mode write
lock blocked the write.
Parameters
enabledboolean— True = strict, false = off.
modules/lsp/setStrictMode
setStrictMode(mode: StrictMode): boolean
Set the pre-execute strict gate's mode. Returns true when the
change was persisted to .world_settings, false when the
play-mode write lock blocked the write.
Parameters
modeStrictMode—"off"|"soft"|"strict".
modules/lsp/summary
summary(): Summary
Counts only — does not re-run validation.
modules/lsp/tools
tools(): { ToolEntry }
List every code-mode tool registered in the VFS under
/zero/docs/tools/<category>/<tool>.
modules/lsp/typeOf
typeOf(expr_source: string, context_path: string?): TypeDescriptor
Infer the static type of a Luau expression. When
context_path is given, the file is loaded and walked so the
inference env contains every local + alias in scope at its end.
Parameters
expr_sourcestring— Luau expression source (no surrounding chunk).context_pathstring?(optional) — VFS path whose scope should be visible.
local td = lsp.typeOf("Transform.lookAt", "/zero/source/main.luau")
typed/builtin//modules/api/engine/lsp/lsp/check
lsp.check(path: string, opts: CheckOpts?) -> DiagnosticsResult
Validate a single .luau file in the VFS and return its
diagnostics. A path the check could not read comes back as one
lsp-check-* error naming the path and the reason, so errors == 0
means a code body was read and is clean.
Parameters
pathstring— VFS path.optsCheckOpts(optional) —{ severity?, limit?, context? }.
Returns DiagnosticsResult — Array of diagnostic tables.
local diags = lsp.check("/zero/source/main.luau")
typed/builtin//modules/api/engine/lsp/lsp/checkAll
lsp.checkAll(opts: CheckAllOpts?) -> CheckAllResult
Validate the user's Luau scripts and return an aggregate
summary plus diagnostic list. opts.scope = "user" (default)
skips library mounts; "all" includes them. The sweep is
time-budgeted (ZERO_EXECUTE_INLINE_BUDGET_MS, ~20s by default): if
the budget elapses it returns the partial result gathered so far
with budgetExceeded = true rather than blocking the engine.
Parameters
optsCheckAllOpts(optional) —{ scope?, severity?, limit? }.
Returns CheckAllResult — { filesChecked, errors, warnings, info, hints, budgetExceeded, diagnostics }.
typed/builtin//modules/api/engine/lsp/lsp/checkCode
lsp.checkCode(source: string, opts: CheckOpts?) -> DiagnosticsResult
Validate inline Luau source without a backing file. Useful for checking code before writing it to disk.
Parameters
sourcestring— Luau source.optsCheckOpts(optional) —{ severity?, limit?, context? }.
Returns DiagnosticsResult — Array of diagnostic tables.
typed/builtin//modules/api/engine/lsp/lsp/checkDirty
lsp.checkDirty() -> DiagnosticsResult
Drain the dirty-file set populated by the hot-reload hook, validate each, and return the combined diagnostic list.
Returns DiagnosticsResult — Array of diagnostic tables.
typed/builtin//modules/api/engine/lsp/lsp/describe
lsp.describe(path: string, opts: DescribeOpts?) -> DocEntry?
Inspect a single documented entry. Returns the full doc
table (signature, args, returns, examples, level), or nil.
The path is resolved independently of which root the doc is
registered under and of separator style, so the spelling that reads
off the API surface (renderer.texture.create) finds the entry
registered as globals/renderer/texture/create. A path naming a
binding the engine registered internally answers with the entry a Luau
module publishes over it where there is one, so the signature is the
call content makes; opts.includeInternal answers with the internally
registered entry itself. When a path does not resolve,
lsp.describePaths says what the registry holds near it.
Parameters
pathstring— Doc path (e.g."asset/resolve","renderer.texture.create").optsDescribeOpts(optional) — Optional{ includeInternal? }— default prefers the published entry.
Returns DocEntry? — Full doc table or nil.
local doc = lsp.describe("renderer.texture.create")
typed/builtin//modules/api/engine/lsp/lsp/describePaths
lsp.describePaths(path: string) -> { string }
List the registered doc paths related to path. A path that names
an entry returns every root it is registered under (the first is what
lsp.describe resolves to); a path that names a namespace returns the
entries registered under it. Empty when the registry holds nothing
near the path — so a lookup that returns nil can always be turned into
the list of what does exist.
Parameters
pathstring— Doc path in any spelling ("renderer.texture","ecs/query").
Returns { string } — Array of registered doc paths, most canonical first.
for _, p in ipairs(lsp.describePaths("renderer.texture")) do print(p) end
typed/builtin//modules/api/engine/lsp/lsp/describeTool
lsp.describeTool(path: string) -> string?
Return the full documentation text for a code-mode tool.
Parameters
pathstring— Tool path (e.g."scene/spawnLight").
Returns string? — Full tool docs or nil.
typed/builtin//modules/api/engine/lsp/lsp/docsByKind
lsp.docsByKind(kind: string) -> { MethodSummary }
List every doc whose registration kind matches kind.
Valid: "binding", "runtime_tool", "module", "component",
"library", "lua_export".
Parameters
kindstring— Registration kind.
Returns { MethodSummary } — Array of doc summary tables.
typed/builtin//modules/api/engine/lsp/lsp/getStrictMode
lsp.getStrictMode() -> StrictMode
Return the current strict mode.
Returns StrictMode — "off" | "soft" | "strict".
typed/builtin//modules/api/engine/lsp/lsp/isStrict
lsp.isStrict() -> boolean
Is the pre-execute LSP gate fully strict? False when off or in soft mode.
Returns boolean — True when fully strict.
typed/builtin//modules/api/engine/lsp/lsp/lastCheckGen
lsp.lastCheckGen() -> number
Generation counter — bumped each time the cache is rebuilt. UI polls this to know when to redraw.
Returns number — Generation number.
typed/builtin//modules/api/engine/lsp/lsp/methods
lsp.methods(namespace: string, opts: MethodsOpts?) -> { MethodSummary } | { string }
List every documented method / entry under a namespace. A broad
namespace (ui, renderer) returns a large dump by default, so two
options narrow it: opts.filter keeps only methods whose name (or
doc path) contains the substring, case-insensitively; opts.namesOnly
returns a plain list of method-name strings instead of the full
per-method summary tables — much smaller, and nothing to unwrap. The
listing answers with the surface content calls: an entry registered
internally is left out where its signature spells the __ binding or a
Luau module publishes the same member, and opts.includeInternal lists
every registered entry instead.
Parameters
namespacestring— Namespace name (e.g."entity","modules/Transform").optsMethodsOpts(optional) — Optional{ filter?, namesOnly?, includeInternal? }.
Returns { MethodSummary } | { string } — Array of method summary tables, or plain name strings when namesOnly is set (empty when the namespace is unknown or nothing matches the filter).
for _, name in ipairs(lsp.methods("ui", { namesOnly = true })) do print(name) end
lsp.methods("renderer", { filter = "shadow" })
typed/builtin//modules/api/engine/lsp/lsp/modules
lsp.modules() -> { ModuleEntry }
List every Luau library module the engine currently knows
about — discovered via --!module headers, library scans, and
manually-recorded docs.
typed/builtin//modules/api/engine/lsp/lsp/namespaces
lsp.namespaces(opts: NamespacesOpts?) -> { NamespaceEntry }
List the documentation namespaces reachable from Luau. By
default only namespaces exposing at least one PUBLIC method are
returned, so the list matches what you can actually call — internal
FFI plumbing (e.g. pause, native_entity), whose public surface
lives elsewhere (engine.paused, the entity proxy, …), is left
out. Pass { includeInternal = true } to list every namespace,
internal ones included.
Parameters
optsNamespacesOpts(optional) — Optional{ includeInternal? }— default lists public only.
Returns { NamespaceEntry } — Array of namespace summary tables.
for _, ns in ipairs(lsp.namespaces()) do print(ns.name) end
typed/builtin//modules/api/engine/lsp/lsp/readDirectives
lsp.readDirectives(source: string) -> DirectiveBlock
Parse the leading --! directive block of a Luau source
string. Used by UIs that audit which files have skip directives
and what they suppress.
Parameters
sourcestring— Luau source text.
Returns DirectiveBlock — { mode, codes? }.
typed/builtin//modules/api/engine/lsp/lsp/search
lsp.search(query: string, opts: SearchOpts?) -> { MethodSummary }
Case-insensitive substring search across every registered
doc's path, signature, and description. Hits answer with the surface
content calls: an entry registered internally is left out where its
signature spells the __ binding or a Luau module publishes the same
member, and opts.includeInternal searches every registered entry.
Parameters
querystring— Substring to search for.optsSearchOpts(optional) —{ limit? = 50, includeInternal? }.
Returns { MethodSummary } — Array of method summary tables.
typed/builtin//modules/api/engine/lsp/lsp/setStrict
lsp.setStrict(enabled: boolean) -> boolean
Toggle the pre-execute LSP gate. Returns true when the change
was persisted to .world_settings, false when the play-mode write
lock blocked the write.
Parameters
enabledboolean— True = strict, false = off.
Returns boolean — Persistence signal.
typed/builtin//modules/api/engine/lsp/lsp/setStrictMode
lsp.setStrictMode(mode: StrictMode) -> boolean
Set the pre-execute strict gate's mode. Returns true when the
change was persisted to .world_settings, false when the
play-mode write lock blocked the write.
Parameters
modeStrictMode—"off"|"soft"|"strict".
Returns boolean — Persistence signal.
typed/builtin//modules/api/engine/lsp/lsp/summary
lsp.summary() -> Summary
Counts only — does not re-run validation.
Returns Summary — Counts of cached diagnostics by severity.
typed/builtin//modules/api/engine/lsp/lsp/tools
lsp.tools() -> { ToolEntry }
List every code-mode tool registered in the VFS under
/zero/docs/tools/<category>/<tool>.
typed/builtin//modules/api/engine/lsp/lsp/typeOf
lsp.typeOf(expr_source: string, context_path: string?) -> TypeDescriptor
Infer the static type of a Luau expression. When
context_path is given, the file is loaded and walked so the
inference env contains every local + alias in scope at its end.
Parameters
expr_sourcestring— Luau expression source (no surrounding chunk).context_pathstring(optional) — VFS path whose scope should be visible.
Returns TypeDescriptor — Type descriptor table.
local td = lsp.typeOf("Transform.lookAt", "/zero/source/main.luau")