PageSourceSearch

https://getproposely.com/_next/static/chunks/176.1c3856ed00555b16.js

js getproposely.com collected 2026-10-02 01:30:31 UTC 6,031 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[176],{4654:function(){},9672:function(e,t,n){"use strict";n.d(t,{extractQuestions:function(){return l}});var i=n(6385),o=n(257);let r=o.env.OPENAI_API_KEY?new i.ZP({apiKey:o.env.OPENAI_API_KEY}):null,s=null;async function a(){return o.env.ANTHROPIC_API_KEY?(s||(s=Function('return import("@anthropic-ai/sdk")')().then(e=>{var t,n;return new(null!==(n=null!==(t=null==e?void 0:e.default)&&void 0!==t?t:e.Anthropic)&&void 0!==n?n:e)({apiKey:o.env.ANTHROPIC_API_KEY})}).catch(()=>null)),s):null}async function u(e){var t,n,i,o,s,u,l,c;let{system:h,user:p,maxTokens:d=300}=e,m=Math.min(d,3500),f=await a();if(f){let e=await f.messages.create({model:"claude-haiku-4-5",max_tokens:m,temperature:.7,system:h,messages:[{role:"user",content:p}]}),r=(null===(n=e.content)||void 0===n?void 0:null===(t=n[0])||void 0===t?void 0:t.type)==="text"&&null!==(o=null===(i=e.content[0].text)||void 0===i?void 0:i.trim())&&void 0!==o?o:"";if(r)return r}if(r){let e=(null===(c=(await r.chat.completions.create({model:"gpt-4o-mini",messages:[{role:"system",content:h},{role:"user",content:p}],temperature:.7,max_tokens:m})).choices)||void 0===c?void 0:null===(l=c[0])||void 0===l?void 0:null===(u=l.message)||void 0===u?void 0:null===(s=u.content)||void 0===s?void 0:s.trim())||"";if(e)return e}throw Error("No LLM provider configured. Set ANTHROPIC_API_KEY or OPENAI_API_KEY.")}async function l(e){return await c(e)}async function c(e){let t=e.length>8e3?e.substring(0,8e3)+"\n\n[... job description continues ...]":e;try{let e;let n=Math.min(1500,Math.max(500,Math.floor(t.length/10))),i=await u({system:'You are an expert at identifying questions in job descriptions that require answers from applicants.\n\nYour task is to scan the entire job description and identify ALL questions that require applicant responses, including:\n- Direct questions with question marks ("What is your experience with React?")\n- Imperative statements that ask for information ("Tell us about your experience with React", "Share details of your previous projects", "Let us know...")\n- Indirect questions ("We\'d like to know how you approach testing", "We\'re curious about your availability", "Please mention...")\n- Questions without question marks ("What technologies have you worked with")\n- Questions embedded in longer paragraphs\n- Multi-sentence questions\n- List items that ask for information (e.g., "Links to 2-3 projects showcasing your work", "Your availability to start and weekly hour commitment")\n\nEXCLUDE:\n- Section headers (e.g., "What you\'ll do", "Your profile", "Bonus points for", "Requirements", "Qualifications")\n- List items that are simple instructions to provide files/links (e.g., "- Share your GitHub profile", "- Attach your CV")\n- Rhetorical questions (e.g., "Why choose us?", "What are you waiting for?")\n- Statements that don\'t ask for information (e.g., "A great position to be in", "That\'s exactly where you come in")\n- Instructions that aren\'t questions (e.g., "To help us get an initial impression, please send us:")\n\nQUESTION PATTERN EXAMPLES:\n✅ INCLUDE (These are questions):\n- "Tell us about your experience with React" → Question (imperative statement asking for info)\n- "We\'d like to know how you approach testing" → Question (indirect question)\n- "What technologies have you worked with" → Question (direct question, no ? needed)\n- "Share details of your previous projects" → Question (imperative asking for details)\n- "Please describe your availability" → Question (imperative asking for info)\n- "Links to 2-3 projects showcasing your work" → Question (list item asking for information)\n- "Your availability to start and weekly hour commitment" → Question (list item asking for info)\n- "A quick video where you briefly present something you built" → Question (list item asking for info)\n\n❌ EXCLUDE (These are NOT questions):\n- "Share your GitHub profile" → Not a question (simple instruction to provide a link/file)\n- "What you\'ll do" → Not a question (section header)\n- "Your profile" → Not a question (section header)\n- "To help us get an initial impression, please send us:" → Not a question (instruction)\n- "- Attach your CV" → Not a question (simple instruction to attach a file)\n\nCRITICAL: The key difference is whether it asks for a TEXTUAL RESPONSE (question) vs. just providing a link/file/attachment (instruction).\n\nReturn ONLY a valid JSON array with this exact structure:\n[\n  {\n    "question": "Clean question text (complete, even if multi-sentence)",\n    "context": "Brief context snippet (1-2 sentences) from the job description where this question appears",\n    "type": "experience" | "approach" | "availability" | "other",\n    "requiresAnswer": true\n  }\n]\n\nCategorization:\n- "experience": Questions about past work, skills, qualifications, or background\n- "approach": Questions about methodology, process, or how the applicant would solve problems\n- "availability": Questions about when or how much the applicant can work\n- "other": Any other direct question requiring an answer',user:"Job Description:\n".concat(t,"\n\nIdentify all questions that require answers from applicants. Return a JSON array with the structure specified above."),maxTokens:n});try{let t=i.match(/\[[\s\S]*\]/);e=t?JSON.parse(t[0]):JSON.parse(i)}catch(e){return console.warn("[QuestionExtractor] Failed to parse JSON response:",i),[]}let o=[];
1return e.forEach(e=>{if(e.requiresAnswer&&e.question&&e.question.trim().length>0){var n;let i=["experience","approach","availability","other"].includes(e.type)?e.type:"other";o.push({id:"undefined"!=typeof crypto&&crypto.randomUUID?crypto.randomUUID():"".concat(Date.now(),"-").concat(Math.random().toString(36).substring(2,9)),question:e.question.trim(),context:(null===(n=e.context)||void 0===n?void 0:n.trim())||t.substring(0,200),type:i,requiresAnswer:!0})}}),o}catch(e){return console.error("[QuestionExtractor] Error in LLM detection:",e),[]}}}}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.