
legends-geogrid: open-source Google Maps rank tracker with radial hex cartography built to end square grids

Cosmi’s Deli ranks in the top three at 38 of 513 search points around South Philadelphia for hoagie, 7 for sandwich shop, and 2 for cheesesteak. Ask a single-point rank tracker where that business stands on Google Maps and it gives you one number that hides the other 512 neighborhoods.
149 first-place Google Maps winners across all 513 radial hex origins (Cosmi's Deli, sandwich shop, 6-mile radial hexagonal lattice with 100% circular coverage). Every territory boundary and contour ring is measured public data you can open locally for $0.
The human is the controller. The agents do the operating.
legends-geogrid turns your coding agent into a local rank tracker, radial hexagonal lattice Google Maps engine, storefront signage and branding auditor, and 30-layer vector-hex PDF strategy studio. Clone the repository or install it through cto-legends, and the complete 513-point South Philadelphia study opens in your browser with no API keys and zero spend.
Specification & local visibility guide: cto-legends.com/modules/legends-geogrid · The 60-Minute AI Visibility Audit and Fix Scorecard

Use cto-legends to install legends-geogrid, then open the bundled South Philadelphia
sandwich shop study so I can explore it without spending credits.

Plain english · 513 ranks · Measurement honesty · In the box · Views & viewer · Cost · Boundaries · FAQ · Reference
None of this asks you to memorize command flags. You describe what you want in plain english, and cto-legends routes the job to legends-geogrid and its sibling modules.

Start with the free part. Say “Open the bundled South Philly study” and your agent builds one self-contained HTML file and opens it in your browser, with no server running, no port open, and no account anywhere.
Then name a business. Your agent reads its website, its public Google Business Profile, and live search demand, and comes back with a proposal: the 3 to 5 search themes it would study, the full circular honeycomb of points, and the exact dollar cost ceiling.
Nothing is bought until you approve that proposal. After you do, the points are collected at raw provider rates, every response is cached on your disk with SHA-256 verification, and an interrupted run resumes from its local ledger without paying twice.
If you have ever had to explain why a business looks number one from its own front counter and vanishes two miles down the road, flip between hoagie, sandwich shop, and cheesesteak on the bundled South Philadelphia map and star the repo if the territory changes your answer. Prefer to watch first? The 31-minute walkthrough runs a full study on screen.
You do not have a rank. You have 513 of them
Stand at the front counter of a sandwich shop on South 8th Street in Philadelphia and search for hoagie. Now walk ten blocks, run the same search for sandwich shop or cheesesteak, and a completely different list comes back.
Ask where a business ranks on Google Maps and the only accurate answer is two more questions. Ranked from where, and for which search?
Google answers a map search from the coordinate where the searcher is standing. Change two words in the query and the list shifts again.
The study bundled with legends-geogrid v0.3.3 measured that around one real South Philadelphia deli using public Google Maps results. Cosmi’s Deli sits at 1501 S 8th St, and all 513 search points surround it on a complete 6-mile circular honeycomb (0.5-mile spacing, 100% circular coverage with zero water pins dropped), each running three searches thirty results deep.
For hoagie, Cosmi’s Deli holds 13 first-place wins, 38 top-three pins, and 149 top-ten pins. For sandwich shop in the exact same neighborhoods, top-three drops to 7. For cheesesteak, visibility collapses past 1 mile (only 2 top-three pins).
30-layer marching-squares rank topography for hoagie (13 #1 crown wins in cyan, 38 three-pack pins in emerald, 149 Page 1 pins in gold, fading to Page 3 crimson) across all 513 radial hex origins. Packed contour lines expose steep ranking cliffs street by street.
So which one is its rank? Any single number has to pick one of those maps and throw the others away. It also throws away the two things an owner can act on: the neighborhood and the search theme. “We rank number four” tells nobody which streets to defend or which service page to write.
Interactive Rankings studio: full 30-layer rank topography with independent topography, triangles, pins, and rings toggles alongside all 1,179 observed Google Maps profiles. Click any rival in the right rail to recolor the entire map to their footprint.

Why paying for square rank grids is a geometric tax
Every major local SEO SaaS tool still sells you square coordinate grids because a nested for x / for y loop is easy to code, not because markets are square. Real trade areas radiate outward from a storefront in circles, and square grids punish you on both accuracy and cost at the same time:
- 21.5% of every square grid is wasted corner deadweight. The four corners of a square sit 41.4% farther (
sqrt(2)) from your storefront than the north, south, east, and west edges. More than 1 in 5 pins you pay for sits outside your actual target radius in distant corner zip codes, dragging down your average rank and Share of Local Voice with irrelevant outer-ring noise.
- Square grids have +41.4% diagonal blind spots. Each interior pin in a square grid has only 4 close neighbors; diagonal neighbors sit 41.4% farther apart, leaving uneven blind pockets between diagonal pins (worst-case blind spot
0.707s). In a radial hexagonal lattice (circular honeycomb), every interior pin has 6 equidistant neighbors at 60-degree symmetry, cutting the worst-case blind spot by 18.4% at the same spacing (0.577s) or 12.3% at the same pin density.
- 39.5% fewer pins for the exact same blind-spot accuracy with 100% complete circular coverage. By Kershner’s optimal 2D covering theorem, hexagonal packing requires 23.0% fewer pins than a square grid to guarantee the exact same maximum blind-spot distance inside the same area. Combine circular radius clipping (21.5% dead corners cut) with hexagonal packing (23.0% fewer pins), and a radial hexagonal lattice needs 39.5% fewer pins for equal worst-case accuracy with zero dead square corners. Matching the
0.289 mi worst-case blind spot of our full 513-pin South Philadelphia radial hex study ($0.92 wholesale for 3 searches) would require a 31x31 square grid (961 pins), nearly double the API calls.
- Nested halving ladder without paying twice.
tools/hex_sampling.py refines spacing on a halving ladder (4 -> 2 -> 1 -> 0.5 mi) where every coarse coordinate stays an exact subset of the finer rung, so zooming in on a contested corridor reuses 100% of your existing scans instead of re-buying the whole map.
The searches are selected as carefully as the coordinates. A study covers 3 to 5 researched themes with one representative query each, chosen from the business’s website, its public Google profile, and real search demand, never padded with synonyms.
A Google Maps rank checker has to show its measurements
Maps are persuasive, and that makes a wrong one expensive. This repository keeps a written record of the day one of its own maps misled.
In one regional HVAC study, a recurring competitor disappeared along a perfectly straight line. Markets do not end in straight lines, so on October 18, 2026 a diagnostic went back to four existing points with four searches under three settings: 48 Standard requests, $0.0288.
At one of those points, with the “Search this area” viewport restriction on, the competitor was missing from all four top-30 responses. Switch the restriction off and it came back at positions 5, 14, 8, and 10. That straight edge was a search setting masquerading as the market.
Three rules came out of those 48 requests, and the engine enforces them automatically:
- Open search is the default. The collector sends every point with the viewport restriction off, and a restricted plan is rejected unless it states the displayed-area question it is asking.
- Missing is never drawn as losing. A point with incomplete evidence cannot appear on the map as “not ranked.”
- Blanks stay blank. No rank is invented or interpolated to make the picture look finished, and the soft diamonds between markers are visual blending, never extra searches.
You can read those rules straight off the canvas. Every measured rank is an eight-sided stop sign: cyan at first place through green to yellow at tenth, then red fading out toward thirtieth. A hollow outline means the business was absent from a complete top 30, and a dashed outline means the evidence is incomplete.
Before a study expands past an edge that looks suspiciously clean, your agent reruns paired points on both sides under different settings and keeps each setting as its own run so ranks are never patched together.
Collection travels through legends-dataforseo, the sibling module that dispatches each request to DataForSEO’s Standard Queue for Google Maps. The collector never switches to the pricier Live mode on its own, and every paid command requires both an explicit execute flag and a dollar ceiling before opening a network connection.
Territory campaigns, Local Leaders and the 3-pane Keyword stuffing studio
Finished studies open as a full-screen local web studio with zero server running. Every view below is rendered directly from the bundled South Philadelphia dataset so you can inspect the full detail before running a single scan.
Local Leaders: every first-place winner mapped across the honeycomb
Local Leaders maps who holds #1 in every pocket of the territory with high-contrast rival hues, outside-circle base connectors, live search across all 149 first-place winners, and double-click territory framing.
Local Leaders view: 149 first-place winners across 513 of 513 radial hex pins (sandwich shop), with searchable leader rail and outside-circle base connectors.
Campaigns: Winnability relief, flip seams, and Where not to spend
Campaigns ranks winnable territory plays (Winnability relief contours, smooth weighted Flip seams, Service gap pockets, and Weak pack blockers) while visually highlighting Where not to spend avoid zones such as corridors across rivers, entrenched high-review fortresses, and non-residential refinery or industrial tracts without dropping any pin from the underlying dataset.
Campaigns view: gold Winnability relief strike zones, cyan Hold (1-3) core, and visually highlighted Where not to spend avoid zones including the Point Breeze / PES Refinery tract and the New Jersey corridor across the Delaware River across all 513 measured pins.
Keyword stuffing: 3-pane storefront signage and branding studio
Another view audits competitor business names. When a first-place holder’s title looks packed with extra keywords, your agent refreshes that exact profile through DataForSEO, reads the branding on its website, inspects the profile’s storefront photos and logo (plus optional official Google Street View Static API imagery when you provide your own Google Maps API key, or a 1-click official Google Maps Street View link), and, with legends-jev or multimodal vision, reads the physical lettering on the storefront sign.
In the bundled South Philadelphia study, all 258 of 258 #1 winners were audited (Pending 0): 15 corroborated naming discrepancies were documented (such as Waterfront Gourmet Cafe & Deli - Catering & Events Services in South St, Philadelphia, Cleavers Philadelphia @ Rittenhouse Square, and Grays Ferry Deli ( Now Open Under New Management )), while high-overlap rivals like Philly's Hoagie House and On a Roll Italian Sandwich Co. were optically cleared because their physical signage and logos match their Google titles.
Keyword stuffing 3-pane studio: rival footprint overlap map on the left, storefront photo, official logo, website title diff, and 1-click Street View link in the center, and the filterable 258-winner audit queue on the right with every rating preserved for human review.
Same title, different physical evidence, different rating. A human still validates each reading, and the tool never files an edit or a complaint with Google on your behalf.
Strategy Room: executive briefing docked beside the live map
Strategy Room docks beside the interactive canvas so you can inspect the 513-point footprint KPIs, read the 4 grounded agent campaign plans, and isolate any Where not to spend avoid zone on the map in one click.
Split-pane Strategy Room: top-line territory metrics (513 pins, 1,179 observed profiles), 4 prioritized agent campaign plans, and clickable Where not to spend avoid cards docked directly beside the live 30-layer topography canvas.

Looking for an open source Local Falcon alternative? Here is the trade. There is no hosted subscription dashboard and nothing runs behind your back on a schedule; in exchange you pay raw provider data costs (all 1,539 searches in the bundled 6-mile South Philadelphia study cost $0.92 in data, and a 10-mile study at 0.5-mile spacing is 1,249 points and 4,996 searches, about $3.00), keep every raw response on your own disk, and can inspect the evidence behind every pin.
Watch the full workflow walkthrough on YouTube below:

In the box
Everything in this table ships with the repository, collected from public Google Maps results. Open it before you configure anything.
| Bundled South Philadelphia study |
What you get |
| Business |
Cosmi’s Deli, 1501 S 8th St, Philadelphia, PA 19147 (a public-data case study) |
| Footprint |
6.0-mile radius, 0.5-mile uniform radial hexagonal honeycomb (hex_radius), 513 circular pins (100% full circular coverage) |
| Searches |
sandwich shop, hoagie, cheesesteak |
| Observations |
1,539 point-and-search results, each to depth 30 |
| Field |
1,179 distinct business profiles observed |
| Campaigns |
4 grounded agent campaign plans + 5 avoid zones (including New Jersey corridor across the Delaware River and Point Breeze / PES Refinery industrial tract) |
| Name check |
All 258 #1 winners audited (Pending 0): 15 corroborated discrepancies, automated website captures, provider GBP storefront/logo photos, and official keyless Street View links |
| Report |
5-page 30-layer vector-hex PDF (examples/cosmis-deli-philly/report/report.pdf) |
| Cost to open |
No keys, no account, $0.00 |
Read the South Philadelphia report at examples/cosmis-deli-philly/report/report.pdf and study guide at examples/cosmis-deli-philly/README.md.
Views and the embeddable viewer
| View |
The question it answers |
| Rankings |
Where the business ranks at every point, 1 through 30, with 30-layer hypsometric topography, independent triangles / pins / rings toggles, and 6-point home star |
| Local leaders |
Who holds first place in each neighborhood, with distinct neighbor colors and double-click territory framing |
| Campaigns |
Which home-landmass plays have the highest structural leverage (Winnability relief, Flip seams, Service gap, Weak pack), plus Where not to spend avoid zones |
| Keyword stuffing |
Whether any #1 winner’s GBP title contradicts its storefront signage, captured website branding, logo, or official Street View link |
| Strategy Room |
Executive summary beside the map: grounded agent campaign plans, Where not to spend avoid zones, radial reach matrix, and head-to-head rival matchups |
| Photo Lightbox |
Full-size inspection of provider GBP storefront photos and logos |
| Vector-hex PDF report |
Offline 30-layer marching-squares topography and full circular Local Leaders hex grid generated via tools/report_builder.py --hex-study |
Offline vector-hex PDF plate (Page 5 of 5): full circular Local Leaders hex grid highlighting 412 head-to-head seams where the #2 challenger sits one rank away from flipping #1. Open the full PDF at examples/cosmis-deli-philly/report/report.pdf.
Embeddable report viewer (GeoGridViewer.mount)
Running pnpm build:viewer also builds a standalone, Content Security Policy safe report viewer in dist-viewer/ (geogrid-viewer.js, geogrid-viewer.css, and geogrid-viewer-worker.js). Mounted with GeoGridViewer.mount(element, model, options), it renders the rank pin map, scores, zone statistics, competitor table, and change since the previous scan from a lean geogrid-viewer/v1 model or a full geogrid-companion/v1 study. With perPointListings enabled on a full study, the Location tab lists every captured ranking at the selected coordinate (top 20 first with a show-all toggle and the primary business pinned even beyond rank 20), and the Competitors tab lists every business seen across the grid and recolors the map to any competitor you select. See docs/VIEWER.md and docs/viewer-model.md.
Cost
Fresh studies bill directly to your own DataForSEO account at wholesale provider task rates. This tool adds zero markup.
| Study |
Search tasks |
Standard Queue data cost |
| Bundled South Philadelphia study |
1,539, already collected |
$0.00 to open |
| 6-mile radial hex study (0.5-mi) |
513 points x 3 searches = 1,539 |
about $0.92 |
| 10-mile radius, 0.5-mile spacing |
1,249 points x 4 searches = 4,996 |
about $3.00 |
| Name check on 258 first-place profiles |
258 profile refreshes |
about $0.39 |
Rates in the code: $0.0006 per Standard Queue Maps search at depth 30, $0.0012 for Priority, $0.0020 for Live, and $0.0015 per profile refresh. Check the preflight estimate and the provider’s current pricing before approving a run. Every DataForSEO command requires both --execute and --confirm-cost-usd <ceiling> and aborts before any network call if the estimate exceeds your ceiling.
Ask your agent
| Say this |
What your agent does |
| “Open the bundled South Philly study so I can explore it without spending credits.” |
Runs python tools/study.py --open, builds a static Companion file, and opens it. No keys, no spend; the dark street map loads from keyless OpenFreeMap. |
“Study <business name> on Google Maps.” |
Researches the website, public profile, and search demand, proposes 3 to 5 search themes, shows the circular honeycomb and cost ceiling, and waits for your approval. |
| “Check why a competitor disappears along a straight line on the east edge of our map.” |
Reruns paired points on both sides of the edge with the search restriction on and off, saves that as a separate diagnostic run, and reports who comes back. |
| “Check the first-place holders in this study for keyword stuffing and read their signs.” |
Refreshes exact profiles through the Standard Queue, captures website branding, downloads provider GBP storefront photos/logos (with optional official Street View Static API + 1-click Google Maps Street View links), and runs the optional legends-jev sign check. |
| “Expand this study out to 10 miles.” |
Plans the larger circle at the same spacing with radius_sampling.py, collects only the new outer points on the Standard Queue within your approved budget, composes one complete 10-mile study from the saved scans, and banks it as an expansion of the original. |
| “Render the report.” |
Builds the vector PDF and HTML strategy report and runs page-by-page layout checks on the result. |
Full agent instructions live in AGENTS.md and docs/STUDY-RECIPE.md.
Optional MCP Plug-In: legends-gambit (Open Beta)
Want a circular hexagonal Google Maps rank grid and a 19-page vector hex PDF without wiring up vendor accounts?
legends-geogrid stays 100% local, free, and MIT open source on your own BYO accounts (DATAFORSEO_LOGIN and DATAFORSEO_PASSWORD). That does not change. You can also run deterministic 7-stage keyword & territory planning locally with python tools/study.py plan --seed-keyword "car detailing" --location "Miami, FL" --dry-run or check both setup paths with python tools/geogrid_doctor.py --via-gambit.
If you prefer pay-per-run audits without vendor accounts or subscriptions, legends-gambit (legends-gambit: SEO MCP Server & Market Intelligence by cto-legends, open beta) is an optional hosted MCP plug-in beside it:
- One Streamable HTTP endpoint (
https://gambit.cto-legends.com/mcp) and one Bearer API key. Works in Claude Code, Cursor, Antigravity, Claude Desktop, and OpenCode (open read-only initialize and tools/list discovery)
- Non-expiring prepaid wallet ($10 starter pack skips $50+ upstream vendor deposits, $0/mo, zero subscriptions)
- From $0.05/run: verified SERP ($0.05), keyword demand ($0.05 for up to 25 keywords), competitor teardown ($0.15), market dossier ($0.50), and circular hexagonal Google Maps rank grids ($0.04/hex point: $0.76 for 19 pts, $1.48 for 37 pts, up to $6.76 for 169 pts across 0.5-50 km radius, with a 19-page vector hex PDF)
- Anything above your per-call limit (default $0.25) is quoted first. Failed runs and 24-hour same-wallet repeats cost $0.00, and verified cache hits are at least 60% off
claude mcp add --transport http legends-gambit https://gambit.cto-legends.com/mcp --header "Authorization: Bearer YOUR_API_KEY"
Create an API key at gambit.cto-legends.com/wallet or read the docs at cto-legends.com/gambit. Prefer to run 100% locally with BYO keys? Keep reading. Everything below needs nothing from us.
Boundaries
- Hosted dashboards, white-label portals, and background scheduled tracking are out of scope. You run it locally, and nothing runs in the background behind your back.
- API keys are never bundled. Fresh scans use your own DataForSEO account.
- Profile edits and competitor complaints are never submitted to Google for you.
- Rank share is never converted into invented revenue, call volume, or conversion claims.
- “Not returned” means absent from this top-30 Maps response under the recorded settings. It is not proof of invisibility in every Google experience.
- Results describe Google Maps searches at a recorded zoom and depth. They are not presented as personalized, organic-web, or local-pack rankings.
- Turning the “Search this area” restriction off widens what comes back. It does not guarantee that every business appears.
- Name check ratings are research findings for a person to validate, never an automated violation verdict.
FAQ
How does a local rank tracker measure a whole territory?
Position decides the answer on Google Maps, so one check from a city center describes one spot. This tool searches from hundreds of points on a true circle around the business (309 at five miles and 1,249 at ten with half-mile spacing) and records the top 30 at each coordinate.
Is this an open source Local Falcon alternative?
Yes, if you would rather run the study yourself. Local Falcon is a hosted product, while this is MIT-licensed code that runs on your machine with your own DataForSEO account and leaves every raw response on your disk. It is independent software, not affiliated with or endorsed by Local Falcon.
Can I try this Google Maps rank checker without API keys?
Keys are optional for the first look. The full South Philadelphia study and its 5-page vector-hex PDF report ship in the repo, and python tools/study.py --open opens them with no account and no spend.
Which searches does this local SEO tool study?
Usually 3 to 5 researched themes, with one representative query per theme. Fewer needs a stated reason, and synonyms are never added to pad the count.
Does it track rankings on a schedule?
No. Tracking over time means banking a baseline study and running a monitoring study when you want a new reading, linked in the study library with --relationship monitoring.
What does the keyword stuffing check conclude?
Each individually reviewed profile gets a 0 to 5 concern rating tied to its exact current title, with sources, timestamps, and counterevidence kept. It is a research finding for human review, and missing evidence stays unscored.
What are the diamonds between the markers?
Visual blending only. A diamond mixes the colors of the four measured points around it and is never an extra search or a predicted rank.
Reference
Everything you need to run legends-geogrid through your coding agent is in the guide above. Open these drawers for the CLI command reference, environment setup, disk layout, and attribution details.
CLI reference and agent setup (click to expand)
Agent setup (via cto-legends)
Part of the cto-legends ecosystem. cto-legends is the only registered agent skill; this repository vendors a pinned copy at skills/cto-legends/SKILL.md. Do not register this module as its own standalone skill folder.
| Module |
Its job in a study |
| cto-legends |
The router. Previews and installs this module, then loads its recipe with cto-legends handoff legends-geogrid. |
| legends-dataforseo |
Carries Maps searches, search demand checks, and profile refreshes to DataForSEO. |
| legends-jev |
Optional. Reads storefront signs in profile photos and Street View captures for the name check. |
python -m pip install cto-legends
cto-legends install legends-geogrid
cto-legends install legends-geogrid --apply
cto-legends handoff legends-geogrid
git clone https://github.com/avalonreset/legends-geogrid.git
cd legends-geogrid
python tools/study.py --open
Python 3.11 or newer is all the free map needs. Fresh scans, report rendering, and street basemaps each add one requirements file, and one offline doctor command checks all of it:
python -m pip install -r requirements-dataforseo.txt -r requirements-report.txt -r requirements-basemaps.txt
python -m playwright install chromium
python tools/geogrid_doctor.py --dataforseo --jev --reports --basemaps --check-playwright --json
Commands marked “Both gates” spend nothing unless --execute and --confirm-cost-usd <ceiling> are both passed. Every tools/study.py subcommand also accepts --vault-dir.
| Command |
What it does |
Spend |
python tools/study.py --open |
Builds and opens the static Companion. Options: --study, --research, --name-review, --output, --no-browser, --pdf. |
None |
python tools/study.py website --url <url> --output <file> |
Fetches public business website context over HTTPS. |
None |
python tools/study.py lookup --query <query> --output-dir <dir> |
Looks up the business identity (CID and place ID) before collection. Options: --near, --tier. |
No DataForSEO spend |
python tools/study.py research --request <json> --output-dir <dir> |
Runs search demand research and writes a research ledger. --allow-live is an explicit opt-in. |
Both gates |
python tools/study.py query-review --plan <plan.json> |
Audits search themes, categories, and observation age before collection. |
None |
python tools/study.py validate --plan <plan.json> |
Validates the study contract. Writes nothing. |
None |
python tools/study.py proposal --plan <plan.json> --output-dir <dir> |
Renders the pre-collection proposal with points, searches, and cost ceiling. |
None |
python tools/study.py run --plan <plan.json> --output-dir <dir> |
Validates, then collects and banks checkpoints. |
Both gates |
python tools/study.py assemble --run-dir <dir> --output-config <file> |
Assembles report-config.json from a run directory. |
None |
python tools/study.py battlefield --run-dir <dir> --output-dir <dir> |
Writes the offline territory model, console, and report. |
None |
python tools/study.py enhance --run-dir <dir> --output-dir <dir> |
Adds detail inside an existing square grid without changing its extent (5 x 5 becomes 9 x 9). Reuses fresh banked observations and collects only the added points through Maps Live. |
Both gates |
python tools/study.py bank --plan <plan.json> |
Banks artifacts into the study library with SHA-256 hashes. --relationship baseline, expansion, or monitoring. |
None |
python tools/study.py library-init |
Initializes the study library. |
None |
python tools/competitive_sampling.py --battlefield <model> |
Plans an irregular exploratory footprint around the business and its rivals: citadels, corridor midpoints, 3x3 micro-grids, and compass sentinels. |
None |
python tools/competitive_collect.py --plan <plan.json> --output-dir <dir> |
Collects Google Maps results on the Standard Queue. --allow-live is an explicit opt-in. |
Both gates |
python tools/competitive_export.py --run-dir <dir> --output <file> --compact |
Exports a geogrid-companion/v1 dataset for the Companion. |
None |
python tools/business_name_review.py plan |
Lists first-place profiles and estimates the refresh cost. |
None |
python tools/business_name_review.py submit |
Submits Standard Queue profile refreshes. |
Both gates |
python tools/business_name_review.py retrieve, websites, photos, export, attach |
Retrieves results, captures branding and photos, exports the review, and attaches it to the study. photos --jev adds the sign check. |
No DataForSEO spend |
python tools/strategy_report.py --config <report-config.json> --output-dir <dir> |
Renders the vector PDF and HTML report with layout QA. --basemap, --proof, --require-pdf-qa. |
No DataForSEO spend |
python tools/geogrid_doctor.py |
Offline readiness check. --reports, --dataforseo, --jev, --basemaps, --check-playwright, --json. |
None |
python tools/radius_sampling.py |
Calculates a circular lattice and its cost estimate, for a new study or a radius expansion. |
None |
python tools/radius_compose.py |
Composes one complete radius study from saved scans, such as an inner study plus a newly collected outer ring. Makes no paid requests. |
None |
python tools/sampling_review.py |
Reviews sampling adequacy and boundary cliffs after measurement. |
None |
python tools/verify_pins.py |
Verifies report pins against the raw results. |
None |
python tools/pollution_gate.py |
Probes spread points to reject a polluted keyword. Calls Live directly. |
Both gates |
pnpm dev, pnpm build, pnpm build:viewer, pnpm test, pnpm check |
UI development server, production build, standalone CSP-safe viewer bundle, Python/Node tests, and the full local check suite. |
None |
Raw single-grid and batch runners (tools/local_heatmap_poc.py, tools/bulk_geogrid_runner.py, tools/adaptive_geogrid.py) also require an explicit --diagnostic flag before they will execute. Basemap imagery from Google is optional in reports and needs your own key plus --allow-google-maps-charge. Street maps default to OpenFreeMap with no key.
Disk layout, verification and license (click to expand)
Where things land:
runs/ and bulk-runs/ hold fresh run folders and are ignored by Git.
- Static Companion builds from
python tools/study.py --open land at runs/starter-cosmis-deli-philly/companion.html.
- Report directories hold
report.pdf, report.html, report-model.json, report-qa.json, sampling-review.json, leaders-map.png, and one map-NNN.png per search.
~/.legends-geogrid/vault/GeoGrid is the study library, movable with --vault-dir or GEOGRID_VAULT_DIR. It keeps a catalog, one folder per business, and a hashed manifest per study revision.
Verification:
pnpm check runs the dependency audit, build, Python and viewer tests, the report doctor, a sample dry run, and the report smoke test.
report-qa.json is the page-by-page layout receipt for every rendered report.
- Pin checks run through
python tools/verify_pins.py against the raw results.
Credentials and guardrails:
- DataForSEO credentials are read from the environment:
DATAFORSEO_LOGIN or DATAFORSEO_USERNAME, plus DATAFORSEO_PASSWORD. tools/pollution_gate.py reads only DATAFORSEO_LOGIN, so set that name if you run it. The optional sign check reads TYPESAFE_API_KEY or an explicit --typesafe-api-key-file.
- Secrets are never printed, logged, or embedded in a report.
- Symlink paths are refused on file inputs, key files, and output paths.
- Agent instructions require ordinary visible processes, with no hidden consoles and no hidden background dev servers.
Only public Maps observations, public profile metadata, and public website branding excerpts are in the bundled starter study. It holds no credentials and no account identifiers.
License and attribution:
Independence note: legends-geogrid is not affiliated with or endorsed by DataForSEO, Google, OpenStreetMap, Leaflet, Local Falcon, Search Atlas, or BrightLocal.
Documentation map (click to expand)
AGENTS.md: agent instructions, the free demo launch, and the spend-gate rules.
docs/AGENT-RECIPE.md, docs/STUDY-RECIPE.md, and docs/START_A_STUDY.md: discovery, search selection, collection, and export from end to end.
docs/QUERY_SELECTION_POLICY.md and docs/STUDY_CONTRACT.md: how the 3 to 5 search themes are chosen and validated.
docs/SEARCH_WINDOW_POLICY.md and docs/COMPETITIVE_SAMPLING.md: the straight-edge diagnostic, open search, circular sampling, and radius expansion.
docs/COMPANION.md, docs/VIEWER.md, and docs/viewer-model.md: every map view, color rule, marker state, and the standalone CSP-safe embeddable viewer.
docs/BATTLEFIELD_INTELLIGENCE.md: the Strategy Room, territory campaigns, and head-to-head comparisons.
docs/BUSINESS_NAME_REVIEW.md: the name check rubric and its evidence limits.
docs/ENHANCE.md and docs/STUDY_LIBRARY.md: adding detail inside an existing grid at the same extent, and how baselines, expansions, and monitoring studies are linked in the study library.
docs/BASEMAPS.md and docs/TECHNICAL_NOTES.md: street maps, optional Google tiles, and cache verification.
Start here
Paste the agent handoff block at the top of this page into your coding agent, open the 513-point South Philadelphia territory map in your browser, and see what a true circular Google Maps rank study looks like before spending a cent.

Running a multi-location business or agency and want circular-lattice territory intelligence and Street View signage dossiers applied directly to your markets? Message Avalon Reset at cto-legends.com/dm. The desk is async, so the conversation starts the moment you write and nobody forces you onto a sales call.

Specification & benchmarks on cto-legends.com:
评论