tensorlake: Instructions file for Claude Code

CLAUDE.md

tensorlake CLAUDE.md is an instructions file for Claude Code from tensorlakeai/tensorlake. It costs 2,259 tokens per session, scanned C, original, Apache-2.0.

Repository instructions for a Python software development kit that sends documents to TensorLake and lets users deploy agent-based applications locally or in the cloud.

In plain words
What is it for?
Building the package, formatting and checking Python code, running selected test suites, regenerating gRPC code from protocol definitions, and performing cloud-environment validations.
Why use it?
They collect the commands for building, formatting, checking, and testing the SDK, including tests that need a configured service URL.

Instructions file for Claude Code

Written for Claude Code: the file is CLAUDE.md. Also seen: mentions CLAUDE.md; mentions Claude Code.

This is tensorlakeai/tensorlake's own configuration. It tells Claude Code how to work on tensorlake itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything tensorlake configures →

About the project

Tensorlake is a serverless compute platform for building agent applications with isolated, stateful virtual machines called sandboxes and a runtime for coordinating background work. Developers use the sandboxes to run agents, tools, or code generated by language models, and use the orchestration runtime for long-running agent tasks. The catalogue instructions relate to using Tensorlake's sandbox and orchestration workflows.

tensorlakeai/tensorlake · 1,028 stars · on GitHub · tensorlake.ai

Reuse

Borrowing it

Nothing to install: this file belongs to tensorlakeai/tensorlake. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/tensorlakeai/tensorlake/main/CLAUDE.md
Clone the repo
git clone --depth 1 https://github.com/tensorlakeai/tensorlake

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for tensorlake CLAUDE.md

README.md
[![agentmods](https://agentmods.dev/badge/instructions/tensorlakeai/tensorlake/claude-md/github.svg)](https://agentmods.dev/instructions/tensorlakeai/tensorlake/claude-md)
Your own site
<a href="https://agentmods.dev/instructions/tensorlakeai/tensorlake/claude-md"><img src="https://agentmods.dev/badge/instructions/tensorlakeai/tensorlake/claude-md/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for tensorlake CLAUDE.md

Your own site · 80×15
<a href="https://agentmods.dev/instructions/tensorlakeai/tensorlake/claude-md"><img src="https://agentmods.dev/badge/instructions/tensorlakeai/tensorlake/claude-md.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 2,259 This file is loaded in full into every session.
When invoked 2,259 The same file — it is already loaded in full.
Security scan C 3 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.02259 $0.02259
Opus 5.5 $0.00904 $0.00904
Sonnet 5.5 $0.00452 $0.00452
Haiku 4.5 $0.00226 $0.00226

Measured 7d ago against content hash f6c424f30629, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade C, and why

tensorlake CLAUDE.md scanned grade C with 3 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 7d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Asks for rootmediumPrivilege escalation

A mod that escalates privileges can change anything on the machine, not only the project.

- Commands run as `tl-user` by default. Builder-image checks that start `dockerd` must run as root, e.g. `sudo -n <script>`.

Unrestricted tool accessmediumExcessive agency

A wildcard tool grant or "run any command" leaves no least-privilege boundary at all.

2. **Sandbox SDK** (`src/tensorlake/sandbox`) - Client for creating Sandboxes where users can run arbitrary code, copy files, install packages and etc.

Runs shell commandslowCapability

Expected in a hook, worth knowing in a rule or an instructions file.

return subprocess.run(
CLAUDE.md · 183 lines

How it starts

The opening of the file, as written. The whole thing — 183 lines — stays where its author put it; the contents beside it link to each section on GitHub.

CLAUDE.md

This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.

Project Overview

TensorLake SDK — a Python SDK for serverless agentic applications. Users define applications using decorator-based APIs and deploy them to TensorLake Cloud or run locally.

Common Commands

# Install dependencies and build
make build

# Format code (Black + isort)
make fmt

# Check formatting without modifying
make check

# Run all tests (requires TENSORLAKE_API_URL env var)
make test

# Run a specific test suite
cd tests && ./run_tests.sh --applications
cd tests && ./run_tests.sh --function-executor
cd tests && ./run_tests.sh --cli

# Run a single test file
cd tests && poetry run python path/to/test_file.py

# Regenerate gRPC stubs from .proto files
make build_proto

Manual Cloud Sandbox Validations

For validations that must run inside the real Tensorlake builder image, use a throwaway Python virtualenv with the published tensorlake package. Do this for live environment checks, not normal repo tests.

Key points:

  • Install from PyPI in a fresh venv: python3 -m venv /tmp/tl-validate-venv && /tmp/tl-validate-venv/bin/python -m pip install -q --upgrade pip tensorlake.
  • Read the token of the current tl context, but never print it. ~/.config/tensorlake/contexts.toml says whether it is in the OS keychain or in credentials.toml. The published SDK reads TENSORLAKE_API_KEY; TENSORLAKE_PAT is not enough for sandbox creation.
  • Read organization and project from .tensorlake/config.toml and pass them explicitly to SandboxClient.for_cloud(...). Relying only on environment variables can produce missing scope headers.
  • Create the throwaway sandbox from tensorlake/rootfs-builder, run validation commands, and always delete it with client.delete(sandbox_id) in a finally block.
  • Commands run as tl-user by default. Builder-image checks that start dockerd must run as root, e.g. sudo -n <script>.

Read the full file on GitHub · 183 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 7d ago Changed · -3 lines · -50 tokens per session f6c424f30629
  2. 22d ago Changed · +4 lines · +80 tokens per session f954be7af68f
  3. 1mo ago Changed · +1 lines · +111 tokens per session 7d5b596d1a94
  4. 1mo ago First seen · 181 lines · 2,118 tokens per session scan C c4f244199445

Subscribe to this mod's changes

tensorlake CLAUDE.md is an instructions file published in the GitHub repository tensorlakeai/tensorlake (1,028 stars, last pushed today), licensed Apache-2.0. It adds 2,259 tokens to every session, about $0.0090 per session on Opus 5.5. A static security scan graded it C with 3 findings (asks for root, unrestricted tool access, runs shell commands). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other instructions, from other repositories