项目 / intellicia-public/parastore

intellicia-public/parastore

行业推荐
语言 TypeScript标签 agent-simulationfastapiisometriclitellmllmpathfindingreact-three-fiberretailsynthetic-datathree-js数据更新 2026-11-22 06:48:52 · 仓库 2026-11-21

一段话介绍

用大模型生成的合成消费者,在虚拟零售空间里模拟行走、取货和结算的实验性原型,用来尝试店铺布局、货架摆放等想法。源文写明它不是生产级销售预测工具。按[仓库 README](https://github.com/intellicia-public/parastore)复制后端环境变量并填入模型密钥后,运行 `./scripts/dev.sh`,即可同时启动后端(8000 端口)和前端(5173 端口),再在浏览器打开本机 5173 端口。演示视频见仓库说明中的链接。

本站整理,非 GitHub 官方 description。

官方 description(GitHub API 原样)
Draw a store, generate LLM personas, and watch them shop — an isometric 3D sandbox for synthetic-consumer experiments.
396累计星
14Fork
—峰值日增
0上榜次数
总榜
暂未入榜
日榜
暂未入榜
周榜
暂未入榜
月榜
暂未入榜

官方快照(gh_history.db,2026-11-25):总榜 未进 Top50 · 日榜 未进 Top50 · 周榜未满 7 天基线(官方不生成) · 月榜暂无官方口径;下方四卡为站内趋势聚合(周卡按上榜次数,非官方 7 日增量窗)。

行业与场景

按行业选型 →

大模型应用工程化与评测

适配系统:AI 应用平台、模型评测平台 · 得分 2.4

提供模型接入、编排与效果评测能力,可作为行业 AI 应用的工程底座与质量闸门。

数据仓库建模与指标治理

适配系统:数据仓库、指标管理平台 · 得分 1.3

提供分层建模与指标定义能力,可支撑口径统一、血缘追踪与自助分析。

仿真推演与运筹优化

适配系统:运筹优化引擎、仿真平台 · 得分 1.2

内置求解器/仿真引擎,可用于排班排产、资源分配等约束优化问题。

更多信息

以下三段按该项目自己的 GitHub README 章节摘录(可合理截断并标明);README 没有对应章节的留空,不编造。

我的用法
使用前先复制 backend/.env.example 并填入 LLM API 密钥(勿提交真实密钥),dev.sh 会同时以 uvicorn 起 8000 端口后端和 vite 起 5173 端口前端。
特点或设计要点
Parastore 将 Intellicia 的合成消费者(LLM 生成的虚拟 personas)从问卷调查扩展到实体零售场景,模拟合成顾客在店内的行走、取货与购买行为。
局限和适用边界
该项目是原型,输出为 LLM 推断的合理性结果而非经验证的预测;LLM 调用成本与时延真实存在,角色生成默认每天上限 100 个(可用 PERSONA_DAILY_CAP 环境变量调整);仅支持单店单配置,无多店视图和跨周纵向动态。
星标走势还差一天的数据,明天就能看到曲线
每天 10:30 记一次星标,连续两天后自动生成曲线
首次发现 — · 最近在榜 2026-05-21 · 语言 TypeScript · 贡献者 —
agentllm

GitHub 项目主页介绍

来自 GitHub 仓库 README / 主页介绍正文,原样摘录,共 9,039 字节。

<div align="center">

![Parastore](./.github/assets/parastore_hero.png)

<h1>Parastore</h1>

Build, simulate, and optimize retail spaces with synthetic consumers.

<br>

![Parastore](./.github/assets/intellicia_logo.png)

</div>

## Overview

[intellicia](https://intellicia.co) builds tooling around _synthetic
consumers_ — virtual personas generated by LLMs that we run surveys against
in place of (or alongside) real respondents. Parastore is an experiment in
extending that idea from surveys to **physical retail**: if we can simulate
how a synthetic shopper answers a survey question, can we also simulate how
they walk through a store, what they pick up, and what they end up paying
for?

This repository is a **prototype**, not a production forecasting tool. A
rigorous offline-sales model would need POS history, real foot-traffic data,
SKU-level taxonomies, weather/seasonality signals, queueing dynamics, and a
lot more than what is wired up here. Parastore is closer to a sketch — a
"what if we tried it this way?" — than a finished product. We are open
sourcing it because the sketch itself might be useful: as a starting point
for your own experiments, as a reference for how to wire up an LLM-driven
agent simulation end-to-end, or simply as something fun to play with.


## Screenshots

<div align="center">
<table>
<tr>
<td width="50%"><img src="./.github/assets/screenshot_1.png"></td>
<td width="50%"><img src="./.github/assets/screenshot_2.png"></td>
</tr>
<tr>
<td width="50%"><img src="./.github/assets/screenshot_3.png"></td>
<td width="50%"><img src="./.github/assets/screenshot_4.png"></td>
</tr>
</table>
</div>

## Use Cases

Parastore goes beyond simple 3D visualization. By combining LLM-driven synthetic consumers with physical space simulation, it allows you to test retail strategies in a risk-free environment. 

- **Store Layout & Circulation A/B Testing:** Experiment with different aisle structures, entry points, and customer pathways to optimize traffic flow and eliminate dead zones.
- **Product Placement & Conversion Testing:** Simulate how moving high-margin items or changing rack categories impacts customer engagement and overall purchase conversion rates within the store environment.
- **Acquisition & Renewal Valuation:** Rapidly prototype and evaluate potential store layouts for new acquisitions or upcoming remodels before committing physical resources.

## Simulation Accuracy

<div align="center">
<img src="./.github/assets/predicted_vs_actual_sales.png" width="80%">
</div>

To evaluate performance, this chart compares **actual sales history from a physical convenience store** with **synthetic consumer simulations driven by Parastore**. The analysis covers 500 real customers and 109 different products.

| Metric | Value | Scope |
| :--- | :--- | :--- |
| **Spearman Correlation** | `0.955` | By category |
| **JS-Similarity** | `0.802` | Across all 109 products |
| **NDCG@all** | `0.868` | Across all 109 products |

>_Note: These results were generated via Intellicia's own synthetic consumers, not the synthesis method published in this repo._

## Demo video

<div align="center">

**▶️ Click to Watch the Full Demo Video:**
<a href="https://youtu.be/q_96OIBJTBQ?si=0gMDBfdbokAwhXXo">
<img src="./.github/assets/video_thumbnail.png" width="80%">
</a>
</div>

## Tech stack

- **Backend:** Python 3.13, FastAPI, Pydantic, LiteLLM, Instructor, pathfinding, pandas, openpyxl.
- **Frontend:** React 19, Vite, TypeScript, React Three Fiber (Three.js), TanStack Router/Query, Zustand, Tailwind v4, shadcn/ui, Recharts, ExcelJS.

## Requirements

- Python **3.13+** with [uv](https://github.com/astral-sh/uv)
- Node **20+** with **pnpm 10.33.0** (pinned in `frontend/package.json`)
- An LLM provider API key. The default model is `gemini/gemini-3.1-pro-preview`
  via LiteLLM, so a `GEMINI_API_KEY` works out of the box. To switch
  providers, edit `backend/src/store_emulator/application/config.py` and
  supply the matching `*_API_KEY`.

## Quick start

```bash
cp backend/.env.example backend/.env   # add your LLM API key — DO NOT commit real keys
./scripts/dev.sh
```

`scripts/dev.sh` runs backend (`uvicorn` on `:8000`) and frontend (`vite` on
`:5173`) together. `Ctrl-C` stops both. Open `http://localhost:5173` in a
browser.

### Running each side separately

**Backend**

```bash
cd backend
uv sync
uv run uvicorn store_emulator.server.main:app --reload
```

Health check: `curl http://localhost:8000/api/health`. The interactive
OpenAPI docs are at `http://localhost:8000/docs`.

**Frontend**

```bash
cd frontend
pnpm install
pnpm dev
```

Override the API URL with `VITE_API_URL=http://my-host:port pnpm dev`.

### Build for production

```bash
cd frontend && pnpm build
# backend: no build step — run uvicorn behind a process manager
```

## Usage walkthrough

The "golden path" through the app, end to end:

1. **Create a project.** From the home screen, start a new project and supply
   a real-world store address plus a one-line customer-profile description
   (e.g. _"a small convenience store in a residential neighborhood"_). The
   address grounds the LLM's trade-area analysis.
2. **Generate personas.** On the second page of the create-store wizard,
   trigger the persona pipeline. The LLM analyzes the trade area, builds a
   daily traffic profile per weekday, and produces individual personas for
   each hour of operation. Generation is batched and parallelized; expect
   this to take a minute or two depending on store size and provider latency.
3. **Draw the store layout.** Once the project is created, use the isometric
   grid editor to place shelves, fridges, counters, walls, and entry points.
   Assign product categories to each rack.
4. **Run the simulation.** Hit play. Personas walk in on a wall-clock
   timeline; the 3D view animates their paths in real time. Use the playback
   controls to scrub, pause, or change speed.
5. **Inspect results.** Watch the live dashboard for aggregate metrics
   (visitor count, conversion rate, dwell time, per-rack engagement).

> **Running parastore with the help of an AI assistant** (Claude Code,
> Cursor, …)? Point it at [`USAGE.md`](./USAGE.md). That guide explains
> which inputs the simulation hinges on, the LLM call count for a given
> persona size, and the silent-failure modes worth catching before
> triggering a run.

## Limitations and non-goals

This is a prototype. To set expectations honestly:

- **No ground-truth calibration.** Outputs are LLM-grounded plausibility, not
  validated forecasts. Treat the numbers as illustrative, not predictive.
- **LLM cost and latency are real.** Generating a week of personas for a
  modest store can be hundreds of LLM calls. Plan your provider budget
  accordingly. Persona generation is capped at **100 per day** by default
  (`PERSONA_DAILY_CAP` env var) to keep call counts manageable — the goal
  of the simulator is to compare layout and product-placement variants,
  not to reproduce a real store's full footfall, so a smaller sample is
  usually enough. Raise the cap if you want denser runs and are willing
  to pay the extra LLM cost.
- **Single store, single configuration.** No multi-store fleet view, no
  longitudinal dynamics across weeks, no holiday/seasonality modelling beyond
  what the LLM infers from the address.
- **Product taxonomy is LLM-derived.** There is no real SKU master, pricing
  feed, or inventory model — categories and prices come from the persona
  pipeline.
- **No crowd dynamics.** Pathfinding is per-customer; queueing, congestion,
  and customer-customer interactions are not modeled.
- **APIs and data shapes are not stable.** Expect breaking changes between
  commits.

## License

MIT — see [`LICENSE`](./LICENSE). Dependencies retain their own licenses; see
[`LICENSES-BACKEND.md`](./LICENSES-BACKEND.md) and
[`LICENSES-FRONTEND.txt`](./LICENSES-FRONTEND.txt).

In short: take it, modify it, ship it, sell it — just keep the copyright
notice. No warranty.

## Credits

3D assets in `frontend/public/assets/` are from [Kenney](https://kenney.nl)
and are licensed CC0 1.0 (public domain). No attribution is required, but
huge thanks to Kenney for making these assets freely available — they are
the reason this project looks the way it does.

- `assets/market/` — [Mini Market](https://kenney.nl/assets/mini-market)
- `assets/characters/` — [Mini Characters](https://kenney.nl/assets/mini-characters)
- `assets/ghost/` — [Graveyard Kit](https://kenney.nl/assets/graveyard-kit)

## Contributing

Parastore was built as a side project alongside our main work at intellicia,
and we're publishing it as a snapshot rather than as an actively staffed
open-source project. Issues and PRs are still welcome — we read them and
will engage when we can — but please understand that responses are
best-effort and may take a while, and we may decline changes that don't fit
the direction we use it for internally. If you have a bigger idea in mind,
forks are very much encouraged.
↑