Tool .NET Foundations v1.0.0

F# Interactive

Use F# Interactive (`dotnet fsi`) for .NET exploration, scriptable experiments, package-backed .fsx workflows, quick data transforms, and reproducible command-line probes. USE FOR: .fsx scripts, F# REPL work, #r nuget references, #load composition, interactive type exploration, and small strongly typed experiments before moving code into a project. DO NOT USE FOR: production application code that needs compiled project structure; C# scripting; long-lived automation better expressed as a normal CLI, test, or build target. INVOKES: run dotnet fsi, edit .fsx scripts, load project or source files, and validate snippets against the target SDK.

Trigger On

  • the task asks for F# Interactive, FSI, .fsx, or dotnet fsi
  • a quick typed experiment is needed before changing compiled project code
  • a script should reference NuGet packages directly with #r "nuget: ..."
  • an investigation needs quick access to F# type inference, pattern matching, or pipelines
  • a repeatable one-file probe is better than a temporary project

Workflow

  1. Decide whether the request is a disposable REPL probe, a repeatable .fsx script, or code that should be promoted to a compiled F# project.
  2. Put repeatable work in an .fsx file immediately. Add all required #r, #load, open, input path, and package source directives to the script instead of relying on hidden REPL state.
  3. Keep package references pinned when the script should be reproducible, and use only trusted NuGet feeds or local feeds derived from __SOURCE_DIRECTORY__.
  4. Run the script with dotnet fsi from a clean shell, passing the same arguments the user or CI will use.
  5. Promote the script to an .fsproj when it needs tests, distribution, project references, or long-term CI coverage.

Validate

Use the simplest command that proves the script still runs:

dotnet fsi scripts/check.fsx
dotnet fsi scripts/check.fsx -- arg1 arg2

For scripts that reference packages, run from a clean shell at least once so hidden REPL state cannot mask missing #r, #load, or open directives.

Related skills

Use ManagedCode.Communication when a .NET application needs explicit result objects, structured errors, and predictable service or API boundaries instead of exception-driven…

ManagedCode.Communication

Use ManagedCode.MimeTypes when a .NET application needs consistent MIME type detection, extension mapping, and content-type decisions for uploads, downloads, or HTTP responses.

ManagedCode.MimeTypes

Use the Microsoft.Extensions stack correctly across Generic Host, dependency injection, configuration, logging, options, HttpClientFactory, and other shared infrastructure…

Microsoft.Extensions.*