spectool

Generate ACSL specifications and run Frama-C/WP verification on C programs.

Updated Jun 26, 2026
One-click install
npx skills add https://github.com/leisure118/spectool --skill spectool
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: spectool
Source: https://github.com/leisure118/spectool/tree/main/spectool
Command: npx skills add https://github.com/leisure118/spectool --skill spectool

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires frama-c, veri-clang, python>=3.8, and includes scripts (resource) and references (resource) and assets (resource) components.

What problem does it solve?

This Skill automates the process of generating ACSL specifications and verifying C programs, significantly reducing the manual effort required for formal specification and verification workflows.

Core Features & Use Cases

  • ACSL Specification Generation: Automatically injects ACSL contracts and loop annotations into C source code.
  • Frama-C/WP Verification: Runs Frama-C/WP on annotated C files to verify the specified properties.
  • Use Case: Suppose you have a complex C program that you want to verify for its correctness. You can use this Skill to generate ACSL annotations, run Frama-C/WP, and get verification results.

Quick Start

To run Frama-C/WP on a C file with ACSL annotations, use the command:

spectool verify -f input.acsl.c --timeout 8 --save-stdout wp.log

Frequently Asked Questions about spectool

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I automatically generate ACSL specifications for C programs?

You can automatically generate ACSL specifications by using tools that inject contracts and loop annotations directly into C source code. This process extracts functions, slices projects, and prepares files for formal verification.

How do I run Frama-C/WP verification on annotated C files?

To run Frama-C/WP verification on annotated C files, execute a command that processes the input, applies a timeout, and saves the verification output. This automates checking specified properties and localizes failed goals.

Do I need veri-clang and Python 3.8 to use Frama-C for formal verification?

Yes, formal verification with Frama-C requires veri-clang and Python 3.8 or higher. These dependencies handle standard scripting, process execution, and project slicing for verifying C program correctness.

What is the best way to localize failed verification goals in Frama-C/WP?

The best way to localize failed verification goals in Frama-C/WP is to use an automated workflow that runs the verifier, captures the output log, and pinpoints exactly which ACSL annotations or C functions failed to prove.

How does automated ACSL injection handle admit policies in C code?

Automated ACSL injection handles admit policies by running specific checks during specification generation to detect and manage the usage of //@ admit, ensuring verification integrity within the C code.

Can I verify C program correctness without manually writing formal specifications?

You can verify C program correctness without manually writing formal specifications by using tools that extract functions, inject ACSL contracts automatically, and execute Frama-C/WP to prove program properties deterministically.