First, you need to install pnpm
if you haven't already:
npm install -g pnpm
Next, install the project dependencies using pnpm
:
pnpm install
Temporarily, you will need to download the Motia monorepo and link the @motia/snap
and @motia/dev
dependencies:
- Clone the Motia monorepo:
git clone <motia-monorepo-url>
cd motia-monorepo
pnpm install
- Link the dependencies:
cd packages/core
pnpm link --global @motia/core
cd ../snap
pnpm link --global @motia/snap
To install the Python dependencies, run the following command:
pip install -r requirements.txt
To run the project, use the following command:
pnpm run dev
Once the project is running, execute the following curl
command to test the flow:
curl -X POST http://localhost:3000/vision-agent \
-H "Content-Type: application/json" \
-d '{
"image_url": "https://media.istockphoto.com/id/1079580668/photo/happy-college-students-listening-to-a-lecturer-in-the-classroom.jpg?s=612x612&w=0&k=20&c=Z8GbAuac_J3lUPKT5bI4Uw4GZskBOA0Y_p8A1xOWarw="
}'