File size: 1,031 Bytes
0a6c67f
47482e3
 
 
 
0a6c67f
 
 
47482e3
0a6c67f
 
47482e3
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
---
title: Psyche DB Update
emoji: 🔄
colorFrom: indigo
colorTo: green
sdk: gradio
app_file: app.py
pinned: false
short_description: Push to psyche-private -> rebuild psyche.duckdb + index
---

Webhook receiver for `psyche-org/psyche-private`.

On every change it launches the build Job in `psyche-org`, which updates both
`psyche.duckdb` and `paper_index.json.gz` in `psyche-org/psyche`.

**Why this Space exists rather than a webhook pointing straight at the Job:** a webhook clones only
part of a Job spec. The command and environment survive; the **secrets, volumes, timeout and
namespace do not**. A webhook-triggered Job runs in the personal namespace with no `HF_TOKEN`, so
it cannot read the private builder repo or write the output. A Space keeps its own secrets, so it
can create the Job properly. This process only starts the Job — the Job does the work.

Secrets required: `HF_TOKEN` (write on `psyche-org`), `WEBHOOK_SECRET` (same value as the webhook).

Source: the `psyche-builder` repo, `buildDB/updateSpace/`.