Hiring Pipeline Builder
Run ID: 69b6fa0b896970b089464a502026-03-29HR
PantheraHive BOS
BOS Dashboard

Build a complete hiring pipeline with job descriptions, interview question banks, scoring rubrics, offer letter templates, and onboarding checklists.

The "Hiring Pipeline Builder" workflow has been successfully executed for "AI Technology" with the description "Test run". Below is a comprehensive, professional hiring pipeline designed to attract, assess, and onboard top talent in the AI technology domain.


Hiring Pipeline for AI Technology Roles

Workflow Description: Test run

Topic: AI Technology

Purpose: To establish a robust and repeatable process for recruiting and integrating skilled professionals into AI technology teams, ensuring a high-quality candidate experience and successful new hire integration.


1. Job Descriptions

Here are three sample job descriptions for common roles within AI Technology, designed to attract a diverse pool of qualified candidates.

1.1. Job Description: AI/ML Engineer

Job Title: AI/ML Engineer

Department: Engineering / AI & Machine Learning

Location: [City, State, Country] (Remote/Hybrid options available)

Reports To: Lead AI Engineer / Engineering Manager

About [Company Name]:

[Company Name] is at the forefront of innovation in [industry, e.g., healthcare, finance, retail], leveraging cutting-edge AI and machine learning to [briefly describe company's core mission/impact, e.g., revolutionize patient care, optimize financial markets, personalize customer experiences]. We are a dynamic team of passionate engineers, scientists, and product thinkers dedicated to building intelligent solutions that make a real difference.

The Role:

We are seeking a talented and motivated AI/ML Engineer to join our growing team. You will be instrumental in designing, developing, and deploying machine learning models and AI-driven solutions that power our core products and services. This role requires a strong understanding of ML fundamentals, excellent programming skills, and a passion for solving complex problems with data.

Key Responsibilities:

  • Design, develop, and implement robust machine learning models and algorithms.
  • Build and maintain scalable data pipelines for training and inference.
  • Collaborate with data scientists, product managers, and other engineers to understand requirements and deliver impactful solutions.
  • Evaluate and improve the performance, accuracy, and scalability of ML models.
  • Deploy ML models into production environments and monitor their performance.
  • Conduct experiments and research to explore new AI/ML techniques and technologies.
  • Write clean, maintainable, and well-documented code.
  • Participate in code reviews and contribute to architectural discussions.

Required Qualifications:

  • Bachelor's or Master's degree in Computer Science, Machine Learning, Artificial Intelligence, or a related quantitative field.
  • 3+ years of experience in developing and deploying machine learning models in a production environment.
  • Proficiency in Python and relevant ML libraries (e.g., TensorFlow, PyTorch, scikit-learn).
  • Strong understanding of machine learning algorithms (e.g., supervised, unsupervised, reinforcement learning) and statistical modeling.
  • Experience with data manipulation and analysis using tools like Pandas, SQL.
  • Familiarity with cloud platforms (AWS, GCP, Azure) and MLOps practices.
  • Solid understanding of software engineering principles and best practices.
  • Excellent problem-solving, analytical, and communication skills.

Preferred Qualifications:

  • Experience with distributed computing frameworks (e.g., Spark).
  • Knowledge of deep learning architectures (CNNs, RNNs, Transformers).
  • Familiarity with containerization (Docker, Kubernetes).
  • Experience with real-time ML systems.
  • Contributions to open-source projects or relevant publications.

Why Join Us?

  • Opportunity to work on challenging and impactful AI projects.
  • Collaborative and innovative work environment.
  • Competitive salary, benefits, and equity package.
  • Continuous learning and professional development opportunities.
  • Flexible work arrangements.

[Company Name] is an Equal Opportunity Employer.


1.2. Job Description: AI Research Scientist

Job Title: AI Research Scientist

Department: AI Research & Development

Location: [City, State, Country]

Reports To: Head of AI Research

The Role:

We are seeking an innovative and experienced AI Research Scientist to push the boundaries of artificial intelligence. You will be responsible for conducting fundamental and applied research, developing novel algorithms, and exploring new AI paradigms to solve complex, real-world problems. This role requires a deep theoretical understanding of AI/ML, strong experimental skills, and a proven track record of impactful research.

Key Responsibilities:

  • Lead and conduct cutting-edge research in areas such as [e.g., Natural Language Processing, Computer Vision, Reinforcement Learning, Generative AI].
  • Develop novel AI algorithms, models, and frameworks.
  • Design and execute experiments to validate research hypotheses and evaluate model performance.
  • Publish research findings in top-tier conferences and journals.
  • Translate research prototypes into production-ready solutions in collaboration with engineering teams.
  • Stay abreast of the latest advancements in AI/ML research and technology.
  • Mentor junior researchers and contribute to a vibrant research culture.

Required Qualifications:

  • Ph.D. in Computer Science, Machine Learning, Artificial Intelligence, or a closely related field.
  • 5+ years of relevant research experience, including post-doctoral work or industry research.
  • Strong publication record in top-tier AI/ML conferences (e.g., NeurIPS, ICML, ICLR, CVPR, ACL, EMNLP).
  • Expertise in at least one major AI sub-field (e.g., Deep Learning, Reinforcement Learning, Probabilistic Models).
  • Proficiency in Python and deep learning frameworks (PyTorch, TensorFlow).
  • Demonstrated ability to formulate research problems, design experiments, and interpret results.
  • Excellent written and verbal communication skills, including presentation abilities.

Preferred Qualifications:

  • Experience with large-scale data processing and distributed computing.
  • Familiarity with MLOps and productionizing research outputs.
  • Experience leading research projects or small teams.
  • Contributions to open-source AI libraries or tools.

1.3. Job Description: AI Product Manager

Job Title: AI Product Manager

Department: Product Management

Location: [City, State, Country]

Reports To: Director of Product

The Role:

We are looking for an experienced and visionary AI Product Manager to define and drive the strategy, roadmap, and execution of our AI-powered products. You will bridge the gap between complex AI capabilities and real-world user needs, working closely with engineering, data science, research, and design teams to deliver innovative and impactful solutions.

Key Responsibilities:

  • Define the vision, strategy, and roadmap for AI-driven products, aligning with company goals and market opportunities.
  • Conduct market research, competitor analysis, and customer interviews to identify unmet needs and validate product concepts.
  • Translate complex AI/ML capabilities into clear, actionable product requirements and user stories.
  • Prioritize features and initiatives based on business value, technical feasibility, and strategic impact.
  • Collaborate closely with AI/ML engineers, data scientists, and researchers throughout the product lifecycle, from ideation to launch and iteration.
  • Monitor product performance, analyze data, and gather user feedback to inform product improvements and future development.
  • Communicate product strategy, roadmaps, and progress to stakeholders across the organization.
  • Evangelize AI product capabilities internally and externally.

Required Qualifications:

  • Bachelor's degree in Computer Science, Engineering, Business, or a related field. MBA or advanced degree preferred.
  • 5+ years of product management experience, with at least 2 years focused on AI/ML-powered products.
  • Solid understanding of machine learning concepts, algorithms, and their practical applications.
  • Proven track record of successfully launching and scaling AI products.
  • Experience working with technical teams (AI/ML engineers, data scientists) in an agile environment.
  • Strong analytical skills, with the ability to interpret data and make data-driven decisions.
  • Exceptional communication, presentation, and interpersonal skills.
  • Ability to think strategically while also being hands-on with execution.

Preferred Qualifications:

  • Technical background (e.g., prior experience as an engineer or data scientist).
  • Experience with specific AI domains relevant to the company's industry.
  • Familiarity with product analytics tools and A/B testing methodologies.

2. Interview Question Banks

This section provides a structured question bank for the AI/ML Engineer role, categorized by interview stage and competency. These questions can be adapted for other AI roles.

2.1. Recruiter Phone Screen (15-30 min)

Objective: Assess basic qualifications, cultural fit, compensation expectations, and candidate motivation.

  • Introduction & Motivation:

* "Tell me about your current role and what motivated you to look for a new opportunity."

* "What excites you most about working in AI/ML, and specifically about [Company Name]?"

* "What are your career aspirations for the next 3-5 years?"

  • Experience & Skills (High-level):

* "Can you briefly describe your experience with Python and popular ML frameworks like TensorFlow or PyTorch?"

* "Have you worked on deploying ML models into production? If so, what was that experience like?"

* "What kind of data problems have you enjoyed solving the most?"

  • Logistics & Expectations:

* "What are your salary expectations?" (Be prepared for a range)

* "What is your availability to start a new role?"

* "Are you open to our [remote/hybrid/on-site] work model?"

* "Do you require sponsorship now or in the future?"

  • Candidate Questions:

* "What questions do you have for me about the role or company?"

2.2. Technical Interview - Round 1 (60 min) - Coding & ML Fundamentals

Objective: Evaluate core programming skills, data structures, algorithms, and fundamental machine learning concepts.

  • Coding Challenge (40 min):

* Problem Type: Algorithm design (e.g., array manipulation, string processing, tree traversal, graph problem, dynamic programming). Focus on efficiency and edge cases.

* ML-Specific Coding: Implement a basic ML algorithm from scratch (e.g., k-NN, logistic regression) or a common data preprocessing step (e.g., feature scaling, one-hot encoding).

* Example: "Given a dataset of user reviews and their sentiment labels, write a function that calculates the TF-IDF for a given term across all reviews. Discuss how you would use this for feature engineering."

  • ML Fundamentals (20 min):

* "Explain the bias-variance trade-off. How does it manifest in model training, and how do you address it?"

* "What is overfitting and underfitting? Provide examples and mitigation strategies."

* "Describe the difference between supervised and unsupervised learning, with an example of each."

* "How do you choose an appropriate evaluation metric for a classification problem (e.g., accuracy, precision, recall, F1-score, AUC-ROC)? When would you use each?"

* "Explain gradient descent. What are its variants (e.g., SGD, Adam), and when would you use them?"

2.3. Technical Interview - Round 2 (60 min) - System Design & Advanced ML

Objective: Assess ability to design and scale ML systems, deep dive into advanced ML topics, and problem-solving in a production context.

  • ML System Design (30 min):

* "Design an end-to-end recommendation system for an e-commerce platform. Consider data sources, model training, serving infrastructure, and monitoring."

* "How would you build a real-time fraud detection system using machine learning? What are the key challenges and components?"

* "Describe the architecture for an ML model serving thousands of requests per second. How would you handle latency and scalability?"

  • Advanced ML & Production (30 min):

* "Explain the concept of MLOps. What are its key components, and why is it important?"

* "How do you monitor the performance of an ML model in production? What metrics would you track, and what actions would you take if performance degrades?"

* "Discuss feature engineering techniques for [specific data type, e.g., time series, text, images]. What are some common pitfalls?"

* "When would you choose a deep learning approach over traditional machine learning, and vice-versa?"

* "Describe a time you encountered a significant data quality issue. How did you identify, diagnose, and resolve it?"

* "What are some ethical considerations in AI that you've encountered or thought about? How do you approach fairness or bias in ML models?"

2.4. Hiring Manager Interview (45-60 min) - Team Fit & Strategic Alignment

Objective: Evaluate candidate's leadership potential, alignment with team goals, and ability to contribute to the broader vision.

  • Team & Collaboration:

* "Describe your ideal team environment. What role do you typically play in a team?"

* "Tell me about a time you had to collaborate with a non-technical stakeholder (e.g., product manager, business analyst) on an ML project. What were the challenges, and how did you overcome them?"

* "How do you handle disagreement or constructive criticism from peers or superiors?"

  • Project Experience & Impact:

* "Walk me through your most impactful AI/ML project. What was your specific contribution, and what was the business outcome?"

* "Describe a time an ML project you worked on failed or didn't meet expectations. What did you learn from it?"

* "How do you prioritize your work when faced with multiple competing demands?"

  • Vision & Growth:

* "Where do you see the field of AI/ML heading in the next 5 years, and how do you envision contributing to it?"

* "What areas of AI/ML are you most interested in learning more about or specializing in?"

* "What kind of mentorship or support do you look for in a manager?"

2.5. Behavioral/Cross-functional Interview (45-60 min) - Culture & Problem Solving

Objective: Assess problem-solving approach, communication skills, resilience, and alignment with company values.

  • Problem Solving & Adaptability:

* "Tell me about a challenging problem you faced at work that had nothing to do with your technical skills. How did you approach it?"

* "Describe a situation where you had to quickly learn a new technology or skill. How did you go about it?"

* "Give me an example of a time you had to make a decision with incomplete information. What was the outcome?"

  • Communication & Influence:

* "How do you explain complex technical concepts to a non-technical audience?"

* "Tell me about a time you had to persuade someone to adopt your idea or approach. What was your strategy?"

* "Describe a situation where you received feedback that was difficult to hear. How did you respond?"

  • Initiative & Ownership:

* "Tell me about a time you identified a problem or opportunity and took the initiative to address it, even if it wasn't explicitly your responsibility."

* "Describe a time you had to overcome significant obstacles to achieve a goal. What kept you motivated?"

  • Values Alignment:

* "What values are most important to you in a workplace?"

* "Tell me about a time you demonstrated [Company Value, e.g., customer obsession, innovation, teamwork]."


3. Scoring Rubrics

A standardized scoring rubric ensures objective evaluation and consistency across interviewers. Below is a sample rubric for the AI/ML Engineer role, focusing on key competencies.

3.1. Overall Interviewer Feedback Form & Scoring Rubric

Candidate Name: [Candidate Name]

Role: AI/ML Engineer

Interviewer Name: [Interviewer Name]

Interview Stage: [e.g., Technical Interview - Round 1, Hiring Manager Interview]

Date: [Date]

Recommendation:

  • Strong Hire
  • Hire
  • Leaning Hire
  • Leaning No Hire
  • No Hire
  • Strong No Hire

Overall Comments (Mandatory):

[Provide a summary of the candidate's strengths, weaknesses, and rationale for your recommendation. Include specific examples.]


Competency Scoring Scale:

  • 1 - Significant Gap: Lacks fundamental understanding or practical ability. Requires extensive training/support.
  • 2 - Developing: Basic understanding but limited practical application. Needs significant guidance.
  • 3 - Meets Expectations: Solid understanding and practical application. Can perform tasks independently.
  • 4 - Exceeds Expectations: Deep understanding, consistently applies skills effectively, and can mentor others.
  • 5 - Exceptional: Expert-level knowledge and application. Innovates, leads, and sets best practices.

3.2. Detailed Scoring Rubric for AI/ML Engineer

| Competency Area | Criteria

hiring_pipeline_builder.md
Download as Markdown
Copy all content
Full output as text
Download ZIP
IDE-ready project ZIP
Copy share link
Permanent URL for this run
Get Embed Code
Embed this result on any website
Print / Save PDF
Use browser print dialog
\n\n\n"); var hasSrcMain=Object.keys(extracted).some(function(k){return k.indexOf("src/main")>=0;}); if(!hasSrcMain) zip.file(folder+"src/main."+ext,"import React from 'react'\nimport ReactDOM from 'react-dom/client'\nimport App from './App'\nimport './index.css'\n\nReactDOM.createRoot(document.getElementById('root')!).render(\n \n \n \n)\n"); var hasSrcApp=Object.keys(extracted).some(function(k){return k==="src/App."+ext||k==="App."+ext;}); if(!hasSrcApp) zip.file(folder+"src/App."+ext,"import React from 'react'\nimport './App.css'\n\nfunction App(){\n return(\n
\n
\n

"+slugTitle(pn)+"

\n

Built with PantheraHive BOS

\n
\n
\n )\n}\nexport default App\n"); zip.file(folder+"src/index.css","*{margin:0;padding:0;box-sizing:border-box}\nbody{font-family:system-ui,-apple-system,sans-serif;background:#f0f2f5;color:#1a1a2e}\n.app{min-height:100vh;display:flex;flex-direction:column}\n.app-header{flex:1;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:12px;padding:40px}\nh1{font-size:2.5rem;font-weight:700}\n"); zip.file(folder+"src/App.css",""); zip.file(folder+"src/components/.gitkeep",""); zip.file(folder+"src/pages/.gitkeep",""); zip.file(folder+"src/hooks/.gitkeep",""); Object.keys(extracted).forEach(function(p){ var fp=p.startsWith("src/")?p:"src/"+p; zip.file(folder+fp,extracted[p]); }); zip.file(folder+"README.md","# "+slugTitle(pn)+"\n\nGenerated by PantheraHive BOS.\n\n## Setup\n\`\`\`bash\nnpm install\nnpm run dev\n\`\`\`\n\n## Build\n\`\`\`bash\nnpm run build\n\`\`\`\n\n## Open in IDE\nOpen the project folder in VS Code or WebStorm.\n"); zip.file(folder+".gitignore","node_modules/\ndist/\n.env\n.DS_Store\n*.local\n"); } /* --- Vue (Vite + Composition API + TypeScript) --- */ function buildVue(zip,folder,app,code,panelTxt){ var pn=pkgName(app); var C=cc(pn); var extracted=extractCode(panelTxt); zip.file(folder+"package.json",'{\n "name": "'+pn+'",\n "version": "0.0.0",\n "type": "module",\n "scripts": {\n "dev": "vite",\n "build": "vue-tsc -b && vite build",\n "preview": "vite preview"\n },\n "dependencies": {\n "vue": "^3.5.13",\n "vue-router": "^4.4.5",\n "pinia": "^2.3.0",\n "axios": "^1.7.9"\n },\n "devDependencies": {\n "@vitejs/plugin-vue": "^5.2.1",\n "typescript": "~5.7.3",\n "vite": "^6.0.5",\n "vue-tsc": "^2.2.0"\n }\n}\n'); zip.file(folder+"vite.config.ts","import { defineConfig } from 'vite'\nimport vue from '@vitejs/plugin-vue'\nimport { resolve } from 'path'\n\nexport default defineConfig({\n plugins: [vue()],\n resolve: { alias: { '@': resolve(__dirname,'src') } }\n})\n"); zip.file(folder+"tsconfig.json",'{"files":[],"references":[{"path":"./tsconfig.app.json"},{"path":"./tsconfig.node.json"}]}\n'); zip.file(folder+"tsconfig.app.json",'{\n "compilerOptions":{\n "target":"ES2020","useDefineForClassFields":true,"module":"ESNext","lib":["ES2020","DOM","DOM.Iterable"],\n "skipLibCheck":true,"moduleResolution":"bundler","allowImportingTsExtensions":true,\n "isolatedModules":true,"moduleDetection":"force","noEmit":true,"jsxImportSource":"vue",\n "strict":true,"paths":{"@/*":["./src/*"]}\n },\n "include":["src/**/*.ts","src/**/*.d.ts","src/**/*.tsx","src/**/*.vue"]\n}\n'); zip.file(folder+"env.d.ts","/// \n"); zip.file(folder+"index.html","\n\n\n \n \n "+slugTitle(pn)+"\n\n\n
\n \n\n\n"); var hasMain=Object.keys(extracted).some(function(k){return k==="src/main.ts"||k==="main.ts";}); if(!hasMain) zip.file(folder+"src/main.ts","import { createApp } from 'vue'\nimport { createPinia } from 'pinia'\nimport App from './App.vue'\nimport './assets/main.css'\n\nconst app = createApp(App)\napp.use(createPinia())\napp.mount('#app')\n"); var hasApp=Object.keys(extracted).some(function(k){return k.indexOf("App.vue")>=0;}); if(!hasApp) zip.file(folder+"src/App.vue","\n\n\n\n\n"); zip.file(folder+"src/assets/main.css","*{margin:0;padding:0;box-sizing:border-box}body{font-family:system-ui,sans-serif;background:#fff;color:#213547}\n"); zip.file(folder+"src/components/.gitkeep",""); zip.file(folder+"src/views/.gitkeep",""); zip.file(folder+"src/stores/.gitkeep",""); Object.keys(extracted).forEach(function(p){ var fp=p.startsWith("src/")?p:"src/"+p; zip.file(folder+fp,extracted[p]); }); zip.file(folder+"README.md","# "+slugTitle(pn)+"\n\nGenerated by PantheraHive BOS.\n\n## Setup\n\`\`\`bash\nnpm install\nnpm run dev\n\`\`\`\n\n## Build\n\`\`\`bash\nnpm run build\n\`\`\`\n\nOpen in VS Code or WebStorm.\n"); zip.file(folder+".gitignore","node_modules/\ndist/\n.env\n.DS_Store\n*.local\n"); } /* --- Angular (v19 standalone) --- */ function buildAngular(zip,folder,app,code,panelTxt){ var pn=pkgName(app); var C=cc(pn); var sel=pn.replace(/_/g,"-"); var extracted=extractCode(panelTxt); zip.file(folder+"package.json",'{\n "name": "'+pn+'",\n "version": "0.0.0",\n "scripts": {\n "ng": "ng",\n "start": "ng serve",\n "build": "ng build",\n "test": "ng test"\n },\n "dependencies": {\n "@angular/animations": "^19.0.0",\n "@angular/common": "^19.0.0",\n "@angular/compiler": "^19.0.0",\n "@angular/core": "^19.0.0",\n "@angular/forms": "^19.0.0",\n "@angular/platform-browser": "^19.0.0",\n "@angular/platform-browser-dynamic": "^19.0.0",\n "@angular/router": "^19.0.0",\n "rxjs": "~7.8.0",\n "tslib": "^2.3.0",\n "zone.js": "~0.15.0"\n },\n "devDependencies": {\n "@angular-devkit/build-angular": "^19.0.0",\n "@angular/cli": "^19.0.0",\n "@angular/compiler-cli": "^19.0.0",\n "typescript": "~5.6.0"\n }\n}\n'); zip.file(folder+"angular.json",'{\n "$schema": "./node_modules/@angular/cli/lib/config/schema.json",\n "version": 1,\n "newProjectRoot": "projects",\n "projects": {\n "'+pn+'": {\n "projectType": "application",\n "root": "",\n "sourceRoot": "src",\n "prefix": "app",\n "architect": {\n "build": {\n "builder": "@angular-devkit/build-angular:application",\n "options": {\n "outputPath": "dist/'+pn+'",\n "index": "src/index.html",\n "browser": "src/main.ts",\n "tsConfig": "tsconfig.app.json",\n "styles": ["src/styles.css"],\n "scripts": []\n }\n },\n "serve": {"builder":"@angular-devkit/build-angular:dev-server","configurations":{"production":{"buildTarget":"'+pn+':build:production"},"development":{"buildTarget":"'+pn+':build:development"}},"defaultConfiguration":"development"}\n }\n }\n }\n}\n'); zip.file(folder+"tsconfig.json",'{\n "compileOnSave": false,\n "compilerOptions": {"baseUrl":"./","outDir":"./dist/out-tsc","forceConsistentCasingInFileNames":true,"strict":true,"noImplicitOverride":true,"noPropertyAccessFromIndexSignature":true,"noImplicitReturns":true,"noFallthroughCasesInSwitch":true,"paths":{"@/*":["src/*"]},"skipLibCheck":true,"esModuleInterop":true,"sourceMap":true,"declaration":false,"experimentalDecorators":true,"moduleResolution":"bundler","importHelpers":true,"target":"ES2022","module":"ES2022","useDefineForClassFields":false,"lib":["ES2022","dom"]},\n "references":[{"path":"./tsconfig.app.json"}]\n}\n'); zip.file(folder+"tsconfig.app.json",'{\n "extends":"./tsconfig.json",\n "compilerOptions":{"outDir":"./dist/out-tsc","types":[]},\n "files":["src/main.ts"],\n "include":["src/**/*.d.ts"]\n}\n'); zip.file(folder+"src/index.html","\n\n\n \n "+slugTitle(pn)+"\n \n \n \n\n\n \n\n\n"); zip.file(folder+"src/main.ts","import { bootstrapApplication } from '@angular/platform-browser';\nimport { appConfig } from './app/app.config';\nimport { AppComponent } from './app/app.component';\n\nbootstrapApplication(AppComponent, appConfig)\n .catch(err => console.error(err));\n"); zip.file(folder+"src/styles.css","* { margin: 0; padding: 0; box-sizing: border-box; }\nbody { font-family: system-ui, -apple-system, sans-serif; background: #f9fafb; color: #111827; }\n"); var hasComp=Object.keys(extracted).some(function(k){return k.indexOf("app.component")>=0;}); if(!hasComp){ zip.file(folder+"src/app/app.component.ts","import { Component } from '@angular/core';\nimport { RouterOutlet } from '@angular/router';\n\n@Component({\n selector: 'app-root',\n standalone: true,\n imports: [RouterOutlet],\n templateUrl: './app.component.html',\n styleUrl: './app.component.css'\n})\nexport class AppComponent {\n title = '"+pn+"';\n}\n"); zip.file(folder+"src/app/app.component.html","
\n
\n

"+slugTitle(pn)+"

\n

Built with PantheraHive BOS

\n
\n \n
\n"); zip.file(folder+"src/app/app.component.css",".app-header{display:flex;flex-direction:column;align-items:center;justify-content:center;min-height:60vh;gap:16px}h1{font-size:2.5rem;font-weight:700;color:#6366f1}\n"); } zip.file(folder+"src/app/app.config.ts","import { ApplicationConfig, provideZoneChangeDetection } from '@angular/core';\nimport { provideRouter } from '@angular/router';\nimport { routes } from './app.routes';\n\nexport const appConfig: ApplicationConfig = {\n providers: [\n provideZoneChangeDetection({ eventCoalescing: true }),\n provideRouter(routes)\n ]\n};\n"); zip.file(folder+"src/app/app.routes.ts","import { Routes } from '@angular/router';\n\nexport const routes: Routes = [];\n"); Object.keys(extracted).forEach(function(p){ var fp=p.startsWith("src/")?p:"src/"+p; zip.file(folder+fp,extracted[p]); }); zip.file(folder+"README.md","# "+slugTitle(pn)+"\n\nGenerated by PantheraHive BOS.\n\n## Setup\n\`\`\`bash\nnpm install\nng serve\n# or: npm start\n\`\`\`\n\n## Build\n\`\`\`bash\nng build\n\`\`\`\n\nOpen in VS Code with Angular Language Service extension.\n"); zip.file(folder+".gitignore","node_modules/\ndist/\n.env\n.DS_Store\n*.local\n.angular/\n"); } /* --- Python --- */ function buildPython(zip,folder,app,code){ var title=slugTitle(app); var pn=pkgName(app); var src=code.replace(/^\`\`\`[\w]*\n?/m,"").replace(/\n?\`\`\`$/m,"").trim(); var reqMap={"numpy":"numpy","pandas":"pandas","sklearn":"scikit-learn","tensorflow":"tensorflow","torch":"torch","flask":"flask","fastapi":"fastapi","uvicorn":"uvicorn","requests":"requests","sqlalchemy":"sqlalchemy","pydantic":"pydantic","dotenv":"python-dotenv","PIL":"Pillow","cv2":"opencv-python","matplotlib":"matplotlib","seaborn":"seaborn","scipy":"scipy"}; var reqs=[]; Object.keys(reqMap).forEach(function(k){if(src.indexOf("import "+k)>=0||src.indexOf("from "+k)>=0)reqs.push(reqMap[k]);}); var reqsTxt=reqs.length?reqs.join("\n"):"# add dependencies here\n"; zip.file(folder+"main.py",src||"# "+title+"\n# Generated by PantheraHive BOS\n\nprint(title+\" loaded\")\n"); zip.file(folder+"requirements.txt",reqsTxt); zip.file(folder+".env.example","# Environment variables\n"); zip.file(folder+"README.md","# "+title+"\n\nGenerated by PantheraHive BOS.\n\n## Setup\n\`\`\`bash\npython3 -m venv .venv\nsource .venv/bin/activate\npip install -r requirements.txt\n\`\`\`\n\n## Run\n\`\`\`bash\npython main.py\n\`\`\`\n"); zip.file(folder+".gitignore",".venv/\n__pycache__/\n*.pyc\n.env\n.DS_Store\n"); } /* --- Node.js --- */ function buildNode(zip,folder,app,code){ var title=slugTitle(app); var pn=pkgName(app); var src=code.replace(/^\`\`\`[\w]*\n?/m,"").replace(/\n?\`\`\`$/m,"").trim(); var depMap={"mongoose":"^8.0.0","dotenv":"^16.4.5","axios":"^1.7.9","cors":"^2.8.5","bcryptjs":"^2.4.3","jsonwebtoken":"^9.0.2","socket.io":"^4.7.4","uuid":"^9.0.1","zod":"^3.22.4","express":"^4.18.2"}; var deps={}; Object.keys(depMap).forEach(function(k){if(src.indexOf(k)>=0)deps[k]=depMap[k];}); if(!deps["express"])deps["express"]="^4.18.2"; var pkgJson=JSON.stringify({"name":pn,"version":"1.0.0","main":"src/index.js","scripts":{"start":"node src/index.js","dev":"nodemon src/index.js"},"dependencies":deps,"devDependencies":{"nodemon":"^3.0.3"}},null,2)+"\n"; zip.file(folder+"package.json",pkgJson); var fallback="const express=require(\"express\");\nconst app=express();\napp.use(express.json());\n\napp.get(\"/\",(req,res)=>{\n res.json({message:\""+title+" API\"});\n});\n\nconst PORT=process.env.PORT||3000;\napp.listen(PORT,()=>console.log(\"Server on port \"+PORT));\n"; zip.file(folder+"src/index.js",src||fallback); zip.file(folder+".env.example","PORT=3000\n"); zip.file(folder+".gitignore","node_modules/\n.env\n.DS_Store\n"); zip.file(folder+"README.md","# "+title+"\n\nGenerated by PantheraHive BOS.\n\n## Setup\n\`\`\`bash\nnpm install\n\`\`\`\n\n## Run\n\`\`\`bash\nnpm run dev\n\`\`\`\n"); } /* --- Vanilla HTML --- */ function buildVanillaHtml(zip,folder,app,code){ var title=slugTitle(app); var isFullDoc=code.trim().toLowerCase().indexOf("=0||code.trim().toLowerCase().indexOf("=0; var indexHtml=isFullDoc?code:"\n\n\n\n\n"+title+"\n\n\n\n"+code+"\n\n\n\n"; zip.file(folder+"index.html",indexHtml); zip.file(folder+"style.css","/* "+title+" — styles */\n*{margin:0;padding:0;box-sizing:border-box}\nbody{font-family:system-ui,-apple-system,sans-serif;background:#fff;color:#1a1a2e}\n"); zip.file(folder+"script.js","/* "+title+" — scripts */\n"); zip.file(folder+"assets/.gitkeep",""); zip.file(folder+"README.md","# "+title+"\n\nGenerated by PantheraHive BOS.\n\n## Open\nDouble-click \`index.html\` in your browser.\n\nOr serve locally:\n\`\`\`bash\nnpx serve .\n# or\npython3 -m http.server 3000\n\`\`\`\n"); zip.file(folder+".gitignore",".DS_Store\nnode_modules/\n.env\n"); } /* ===== MAIN ===== */ var sc=document.createElement("script"); sc.src="https://cdnjs.cloudflare.com/ajax/libs/jszip/3.10.1/jszip.min.js"; sc.onerror=function(){ if(lbl)lbl.textContent="Download ZIP"; alert("JSZip load failed — check connection."); }; sc.onload=function(){ var zip=new JSZip(); var base=(_phFname||"output").replace(/\.[^.]+$/,""); var app=base.toLowerCase().replace(/[^a-z0-9]+/g,"_").replace(/^_+|_+$/g,"")||"my_app"; var folder=app+"/"; var vc=document.getElementById("panel-content"); var panelTxt=vc?(vc.innerText||vc.textContent||""):""; var lang=detectLang(_phCode,panelTxt); if(_phIsHtml){ buildVanillaHtml(zip,folder,app,_phCode); } else if(lang==="flutter"){ buildFlutter(zip,folder,app,_phCode,panelTxt); } else if(lang==="react-native"){ buildReactNative(zip,folder,app,_phCode,panelTxt); } else if(lang==="swift"){ buildSwift(zip,folder,app,_phCode,panelTxt); } else if(lang==="kotlin"){ buildKotlin(zip,folder,app,_phCode,panelTxt); } else if(lang==="react"){ buildReact(zip,folder,app,_phCode,panelTxt); } else if(lang==="vue"){ buildVue(zip,folder,app,_phCode,panelTxt); } else if(lang==="angular"){ buildAngular(zip,folder,app,_phCode,panelTxt); } else if(lang==="python"){ buildPython(zip,folder,app,_phCode); } else if(lang==="node"){ buildNode(zip,folder,app,_phCode); } else { /* Document/content workflow */ var title=app.replace(/_/g," "); var md=_phAll||_phCode||panelTxt||"No content"; zip.file(folder+app+".md",md); var h=""+title+""; h+="

"+title+"

"; var hc=md.replace(/&/g,"&").replace(//g,">"); hc=hc.replace(/^### (.+)$/gm,"

$1

"); hc=hc.replace(/^## (.+)$/gm,"

$1

"); hc=hc.replace(/^# (.+)$/gm,"

$1

"); hc=hc.replace(/\*\*(.+?)\*\*/g,"$1"); hc=hc.replace(/\n{2,}/g,"

"); h+="

"+hc+"

Generated by PantheraHive BOS
"; zip.file(folder+app+".html",h); zip.file(folder+"README.md","# "+title+"\n\nGenerated by PantheraHive BOS.\n\nFiles:\n- "+app+".md (Markdown)\n- "+app+".html (styled HTML)\n"); } zip.generateAsync({type:"blob"}).then(function(blob){ var a=document.createElement("a"); a.href=URL.createObjectURL(blob); a.download=app+".zip"; a.click(); URL.revokeObjectURL(a.href); if(lbl)lbl.textContent="Download ZIP"; }); }; document.head.appendChild(sc); } function phShare(){navigator.clipboard.writeText(window.location.href).then(function(){var el=document.getElementById("ph-share-lbl");if(el){el.textContent="Link copied!";setTimeout(function(){el.textContent="Copy share link";},2500);}});}function phEmbed(){var runId=window.location.pathname.split("/").pop().replace(".html","");var embedUrl="https://pantherahive.com/embed/"+runId;var code='';navigator.clipboard.writeText(code).then(function(){var el=document.getElementById("ph-embed-lbl");if(el){el.textContent="Embed code copied!";setTimeout(function(){el.textContent="Get Embed Code";},2500);}});}