OppaAI commited on
Commit
90365b1
·
verified ·
1 Parent(s): 10adf53

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -36,13 +36,13 @@ def search_jobs_tool(category: str = "",
36
  job_type (str): One of Job Types.
37
  industry (str): Company industry filter.
38
  country (str): Region filter (e.g., usa, canada, ...).
39
- limit (int): Number of results (1–200).
40
 
41
  Returns:
42
  dict: {"jobs": [...]} or {"error": "..." }
43
  """
44
  base = "https://jobicy.com/api/v2/remote-jobs"
45
- params = {"count": max(1, min(limit, 200))}
46
  if category:
47
  params["industry"] = category.lower().replace(" & ", "-").replace(" ", "-")
48
  if job_type:
@@ -106,7 +106,7 @@ app = gr.Interface(
106
  gr.Dropdown(label="Job Type (optional)", choices=JOB_TYPES, value=""),
107
  gr.Dropdown(label="Company Industry (optional)", choices=COMPANY_INDUSTRIES, value=""),
108
  gr.Dropdown(label="Country / Region (optional)", choices=COUNTRY_CHOICES, value="Anywhere"),
109
- gr.Slider(minimum=1, maximum=200, value=20, step=1, label="Number of Results"),
110
  ],
111
  outputs=gr.Markdown(),
112
  title="Jobicy Remote Job Search",
 
36
  job_type (str): One of Job Types.
37
  industry (str): Company industry filter.
38
  country (str): Region filter (e.g., usa, canada, ...).
39
+ limit (int): Number of results (1–50).
40
 
41
  Returns:
42
  dict: {"jobs": [...]} or {"error": "..." }
43
  """
44
  base = "https://jobicy.com/api/v2/remote-jobs"
45
+ params = {"count": max(1, min(limit, 50))}
46
  if category:
47
  params["industry"] = category.lower().replace(" & ", "-").replace(" ", "-")
48
  if job_type:
 
106
  gr.Dropdown(label="Job Type (optional)", choices=JOB_TYPES, value=""),
107
  gr.Dropdown(label="Company Industry (optional)", choices=COMPANY_INDUSTRIES, value=""),
108
  gr.Dropdown(label="Country / Region (optional)", choices=COUNTRY_CHOICES, value="Anywhere"),
109
+ gr.Slider(minimum=1, maximum=50, value=20, step=1, label="Number of Results"),
110
  ],
111
  outputs=gr.Markdown(),
112
  title="Jobicy Remote Job Search",