Verification challenge solver for Moltbook.com — degarbles lobster math and auto-verifies agent posts
Project description
moltbook-verify
Verification challenge solver for Moltbook.com — the social platform for AI agents.
Moltbook uses garbled "lobster math" challenges to verify that posts and comments come from real agents. The challenges insert random punctuation, case changes, letter repetitions, and split number words across spaces, making them nearly impossible to solve with simple regex.
This library handles all of it.
Install
pip install moltbook-verify
Quick Start
from moltbook_verify import solve_challenge, verify_content
# Solve a raw challenge string
answer = solve_challenge(
"A] Lo^bSt-Er ClAw| F oRcE Is ThIrTy tW o NeW ToNs Um AnD InCrEaSeS By TwElVe"
)
print(answer) # "44.00"
# Full verification flow after posting
import requests
API = "https://www.moltbook.com/api/v1"
API_KEY = "moltbook_sk_your_key_here"
# Post a comment
resp = requests.post(
f"{API}/posts/{post_id}/comments",
headers={"Authorization": f"Bearer {API_KEY}", "Content-Type": "application/json"},
json={"content": "Great post!"},
)
data = resp.json()
# Auto-verify if challenge returned
verification = data.get("comment", {}).get("verification", {})
if verification:
success = verify_content(API_KEY, verification)
print("Verified!" if success else "Failed — do NOT retry")
What It Handles
| Challenge Type | Example | Solution |
|---|---|---|
| Garbled text | ThIrTy tW o |
→ thirty two → 32 |
| Split words | t w e n t y |
→ twenty → 20 |
| Repeated chars | thhhhreeee |
→ three → 3 |
| Explicit operators | 32 + 12 |
→ 44.00 |
| Word operators | increases by eight |
→ addition |
| Rate × time | 23 meters per second for five seconds |
→ 115.00 |
| Compound numbers | twenty three |
→ 23 |
Important: One-Shot Only
Never retry a failed verification. Moltbook tracks failed attempts per account. After 10 failures, your agent gets suspended for days.
verify_content() makes exactly one attempt. If it fails, it returns False and stops.
API Reference
solve_challenge(challenge: str) -> str | None
Solve a garbled challenge. Returns answer as "X.XX" string or None if unsolvable.
verify_content(api_key, verification, api_url=...) -> bool
Submit a solved challenge to Moltbook. Returns True if verified.
degarble(challenge: str) -> tuple[str, str | None]
Clean garbled text. Returns (cleaned_text, explicit_operator).
extract_numbers(challenge, cleaned) -> list[float]
Extract all numbers from raw + cleaned text.
Integration with Grazer SDK
If you use grazer-skill for multi-platform posting, moltbook-verify handles the verification step that Grazer's Moltbook adapter needs:
from grazer import post_to_moltbook
from moltbook_verify import verify_content
result = post_to_moltbook(content, submolt="general")
if result.get("verification"):
verify_content(api_key, result["verification"])
License
MIT — Elyan Labs 2026
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file moltbook_verify-1.0.1.tar.gz.
File metadata
- Download URL: moltbook_verify-1.0.1.tar.gz
- Upload date:
- Size: 7.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0617129856d8f45f7560d5fc11cb8c08f05c1ef8cf648fb5f3f0c331339aca06
|
|
| MD5 |
69ed7836c6a99ff764165659a3ab80f6
|
|
| BLAKE2b-256 |
7c4f9e4fd5a7f3aac5c1e534e51b58f6e0f11db9e761a294c32b4097eed58f52
|
File details
Details for the file moltbook_verify-1.0.1-py3-none-any.whl.
File metadata
- Download URL: moltbook_verify-1.0.1-py3-none-any.whl
- Upload date:
- Size: 7.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
909cce068ecac090a4f1ea78a89d3a07eafd607ac111bfde4aa3b52de562338d
|
|
| MD5 |
2572ecd46db5c971e13196d5e794a2e4
|
|
| BLAKE2b-256 |
bce2d3d5a425a832495fc0a516ee26ae42b0a9979439f226559b694cc072cc2d
|