Upload files/tits.md with huggingface_hub
Browse files- files/tits.md +35 -0
files/tits.md
ADDED
|
@@ -0,0 +1,35 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# gh-issue-pull
|
| 2 |
+
|
| 3 |
+
Stateless endpoint to sample obfuscated issues from SWEBench.
|
| 4 |
+
|
| 5 |
+
## Running
|
| 6 |
+
First, set your `.env` using the `.env.example` file. Then:
|
| 7 |
+
|
| 8 |
+
If using poetry:
|
| 9 |
+
```sh
|
| 10 |
+
poetry install && poetry shell
|
| 11 |
+
```
|
| 12 |
+
If using `virtualenv`:
|
| 13 |
+
```sh
|
| 14 |
+
python3 -m venv venv
|
| 15 |
+
source venv/bin/activate
|
| 16 |
+
python3 -m pip install --upgrade pip
|
| 17 |
+
python3 -m pip install -r requirements.txt
|
| 18 |
+
```
|
| 19 |
+
|
| 20 |
+
Then, run the server via:
|
| 21 |
+
```sh
|
| 22 |
+
python3 -m uvicorn gh_issue_pull.main:app --reload
|
| 23 |
+
```
|
| 24 |
+
|
| 25 |
+
The server will take a while to start up as it has to pull all the SWEBench issues and save them to a local db.
|
| 26 |
+
|
| 27 |
+
Test the program by running
|
| 28 |
+
```shell
|
| 29 |
+
curl "http://127.0.0.1:8000/task" | jq
|
| 30 |
+
```
|
| 31 |
+
|
| 32 |
+
If you want to quickly make the endpoint publicly available, the easiest way is to use localtunnel:
|
| 33 |
+
```shell
|
| 34 |
+
lt --port 8000
|
| 35 |
+
```
|