Skip to content
Open
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file added PDFParse/Hongwei_resume.pdf
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You probably want to remove this

Binary file not shown.
59 changes: 59 additions & 0 deletions PDFParse/output.txt
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The output file should be JSON so that is is compatible with chrome local storage. So instead of a output.txt we should have a output.json. Later on we will wont even want an output file and just have it write straight to local storage. One way to format this text as json would be

{
  "name": "HONGWEI LI (DILLON)",
  "phone": "(917) 702-5588",
  "email": "dillon.hongwei.li@gmail.com",
  "location": "New York, NY",
  "summary": "A highly motivated student seeking challenging summer software internship opportunities.",
  "education": [
    {
      "school": "Rensselaer Polytechnic Institute",
      "location": "Troy, NY",
      "degree": "B.S. in Computer Science",
      "gpa": "3.26/4.0",
      "graduation_date": "May 2026",
      "relevant_courses": [
        "Data Structures",
        "Computer Science I",
        "Business and Management"
      ]
    },
    {
      "school": "Stuyvesant High School",
      "location": "New York, NY",
      "degree": "High School Diploma",
      "gpa": "3.5/4.00",
      "graduation_date": "Jun 2022",
      "relevant_courses": [
        "Computer Science",
        "Technical Drawing",
        "3D Modeling",
        "Analog and Applied Electronics"
      ]
    }
  ],
  "professional_experience": [
    {
      "position": "CodePath Android Development",
      "location": "New York, NY",
      "dates": "Feb 2023 – Apr 2023",
      "description": [
        "Learn the basics of Android development including IDEs, Kotlin language, and debugging.",
        "Design and architect a functional multi-screen mobile app in a group setting."
      ]
    },
    {
      "position": "StuyPulse FIRST Robotics Team",
      "location": "New York, NY",
      "dates": "Sep 2019 – Jun 2022",
      "description": [
        "Designed and built prototypes of a feeding mechanism that allows the robot to collect and store balls for shooting.",
        "Gained hands-on experience in machines such as drill press, laser cutter, bandsaw, and belt sander."
      ]
    },
    {
      "position": "Technical Project",
      "location": "New York, NY",
      "dates": "Sep 2021 – Jun 2022",
      "description": [
        "Designed and built circuitry to adjust the LED and seven-segment display using IC chips, ceramic capacitors, resistors, potentiometers, and buttons.",
        "Utilized AutoCAD to design a 3D water bottle jug and created a multi-view drawing with dimensions.",
        "Laser cut a wooden, finger-jointed light box with engraved images and cut-outs."
      ]
    },
    {
      "position": "SAT Prep Center",
      "location": "New York, NY",
      "dates": "Jul 2020 – Aug 2021",
      "description": [
        "Tutored multiple groups of 15 students to enhance their mathematical and English comprehension skills."
      ]
    }
  ],
  "leadership_development": [
    {
      "organization": "Society of Asian Scientists and Engineers (SASE)",
      "location": "Troy, NY",
      "role": "Member, Mentee",
      "dates": "Sep 2022 – Present",
      "description": [
        "Developed professional experience and network through participating in various conferences, workshops, and social events.",
        "Aiming to join the Public Relations Committee to raise awareness of social and service events to the community."
      ]
    },
    {
      "organization": "Eighth Wonder Dance Club",
      "location": "Troy, NY",
      "role": "Treasurer",
      "dates": "Sep 2022 – Present",
      "description": [
        "Handled all income and expenditure of the club while tracking the club funds in a financial report to organize and plan future club events.",
        "Will be coordinating with school officials and monitoring events to request and raise funds for the club."
      ]
    },
    {
      "organization": "PSAL Stunt & Cheer",
      "location": "New York, NY",
      "role": "Cheerleader and Back spotter",
      "dates": "Sep 2018 – Jun 2022",
      "description": [
        "Participated in 5 cheerleading events to support the school’s sports games.",
        "Supervised and mentored new stunt members to facilitate their transition to the team.",
        "Successfully organized 3 in-school fundraisers for the team to participate in national competitions."
      ]
    }
  ],
  "skills": {
    "technical": ["Python", "HTML", "Kotlin", "Scratch", "AutoCAD"],
    "prototyping": ["3D printer", "laser cutter", "horizontal bandsaw", "drill press"],
    "languages": ["Proficient in English and Mandarin"]
  }
}

Essentially we want to break it down into pieces so that when the AI model attempts to autofill something like work experience, it can take the json sections called "Professional Experience" and easily see what goes where as we have sections for the position, title, dates, description, etc. Also txt files aren't compatible with local storage and we definitely don't want to parse a resume every time we want to fill in data.

Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@


HONGWEI LI (DILLON)
(917) 702-5588 | dillon.hongwei.li@gmail.com | New York, NY
A highly motivated student seeking challenging summer software internship opportunities.


EDUCATION
Rensselaer Polytechnic Institute, GPA: 3.26/4.0 Troy, NY
B.S. in Computer Science May 2026
Relevant Courses: Data Structures, Computer Science I, Business and Management.
Stuyvesant High School, GPA: 3.5/4.00 New York, NY
High School Diploma Jun 2022
Relevant Courses: Computer Science, Technical Drawing, 3D Modeling, Analog and Applied Electronics.


PROFESSIONAL EXPERIENCE
CodePath Android Development New York, NY
Project Development Course Feb 2023 – Apr 2023
• Learn the basics of Android development including IDEs, Kotlin language, and debugging.
• Design and architect a functional multi-screen mobile app in a group setting.
StuyPulse FIRST Robotics Team New York, NY
Mechanical Division member Sep 2019 – Jun 2022
• Designed and built prototypes of a feeding mechanism that allows the robot to collect and store balls for shooting.
• Gained hands-on experience in machines such as drill press, laser cutter, bandsaw, and belt sander.
Technical Project New York, NY
High School STEM Course Sep 2021 – Jun 2022
• Designed and built circuitry to adjust the LED and seven-segment display using IC chips, ceramic capacitors,
resistors, potentiometers, and buttons.
• Utilized AutoCAD to design a 3D water bottle jug and created a multi-view drawing with dimensions.
• Laser cut a wooden, finger-jointed light box with engraved images and cut-outs.
SAT Prep Center New York, NY
Teaching Assistant Jul 2020 – Aug 2021
• Tutored multiple groups of 15 students to enhance their mathematical and English comprehension skills.



LEADERSHIP DEVELOPMENT
Society of Asian Scientists and Engineers (SASE) Troy, NY
Member, Mentee Sep 2022 – Present
• Developed professional experience and network through participating in various conferences, workshops, and
social events.
• Aiming to join the Public Relations Committee to raise awareness of social and service events to the community.
Eighth Wonder Dance Club Troy, NY
Treasurer Sep 2022 – Present
• Handled all income and expenditure of the club while tracking the club funds in a financial report to organize and
plan future club events.
• Will be coordinating with school officials and monitoring events to request and raise funds for the club.
PSAL Stunt & Cheer New York, NY
Cheerleader and Back spotter Sep 2018 – Jun 2022
• Participated in 5 cheerleading events to support the school’s sports games.
• Supervised and mentored new stunt members to facilitate their transition to the team.
• Successfully organized 3 in-school fundraisers for the team to participate in national competitions.


SKILLS
Technical: Python, HTML, Kotlin, Scratch, AutoCAD.
Prototyping: 3D printer, laser cutter, horizontal bandsaw, drill press.
Languages: Proficient in English and Mandarin.
121 changes: 121 additions & 0 deletions PDFParse/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 7 additions & 0 deletions PDFParse/package.json
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is there another package.json? Shouldn't you add these dependencies to the package.json in the working directory.

Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"dependencies": {
"node-typescript": "^0.1.3",
"pdf-parse": "^1.1.1",
"readline-sync": "^1.4.10"
}
}
76 changes: 76 additions & 0 deletions PDFParse/pdfparse.js
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Git ignore this

Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
"use strict";
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
return new (P || (P = Promise))(function (resolve, reject) {
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
step((generator = generator.apply(thisArg, _arguments || [])).next());
});
};
var __generator = (this && this.__generator) || function (thisArg, body) {
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
function verb(n) { return function (v) { return step([n, v]); }; }
function step(op) {
if (f) throw new TypeError("Generator is already executing.");
while (g && (g = 0, op[0] && (_ = 0)), _) try {
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
if (y = 0, t) op = [op[0] & 2, t.value];
switch (op[0]) {
case 0: case 1: t = op; break;
case 4: _.label++; return { value: op[1], done: false };
case 5: _.label++; y = op[1]; op = [0]; continue;
case 7: op = _.ops.pop(); _.trys.pop(); continue;
default:
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
if (t[2]) _.ops.pop();
_.trys.pop(); continue;
}
op = body.call(thisArg, _);
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
}
};
Object.defineProperty(exports, "__esModule", { value: true });
var fs = require("fs");
var path = require("path");
var pdf = require("pdf-parse");
var readlineSync = require("readline-sync");
function convertPdfToTxt() {
return __awaiter(this, void 0, void 0, function () {
var pdfPath, dataBuffer, data, textContent, txtPath, error_1;
return __generator(this, function (_a) {
switch (_a.label) {
case 0:
_a.trys.push([0, 2, , 3]);
pdfPath = readlineSync.question('Enter the path to the PDF file: ');
// Check if the file exists
if (!fs.existsSync(pdfPath)) {
console.error('Error: The specified file does not exist.');
return [2 /*return*/];
}
dataBuffer = fs.readFileSync(pdfPath);
return [4 /*yield*/, pdf(dataBuffer)];
case 1:
data = _a.sent();
textContent = data.text;
txtPath = path.join(__dirname, 'output.txt');
// Write text content to a TXT file
fs.writeFileSync(txtPath, textContent);
console.log('Conversion successful! Text saved to output.txt');
return [3 /*break*/, 3];
case 2:
error_1 = _a.sent();
console.error('Error converting PDF to TXT:', error_1.message);
return [3 /*break*/, 3];
case 3: return [2 /*return*/];
}
});
});
}
// Call the function to start the conversion
convertPdfToTxt();
39 changes: 39 additions & 0 deletions PDFParse/pdfparse.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
import * as fs from 'fs';
import * as path from 'path';
import * as pdf from 'pdf-parse';
import * as readlineSync from 'readline-sync';

async function convertPdfToTxt(): Promise<void> {
try {
// Get PDF file path from user input
const pdfPath = readlineSync.question('Enter the path to the PDF file: ');

// Check if the file exists
if (!fs.existsSync(pdfPath)) {
console.error('Error: The specified file does not exist.');
return;
}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Getting files is gonna work a little differently that this but for testing this is file I guess. Rather then having the user enter the path we should just have a set path like /PDFParse/parse.pdf would be the default name.


// Read PDF file
const dataBuffer = fs.readFileSync(pdfPath);

// Parse PDF
const data = await pdf(dataBuffer);

// Extract text content
const textContent = data.text;

// Create output file path
const txtPath = path.join(__dirname, 'output.txt');
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Output as json


// Write text content to a TXT file
fs.writeFileSync(txtPath, textContent);

console.log('Conversion successful! Text saved to output.txt');
} catch (error) {
console.error('Error converting PDF to TXT:', error.message);
}
}

// Call the function to start the conversion
convertPdfToTxt();
49 changes: 49 additions & 0 deletions PDFParse/pdfsort.js
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Git ignore this

Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
var fs = require("fs");
var path = require("path");
function isName(line, isFirstNonEmptyLine) {
var trimmedLine = line.trim();
return isFirstNonEmptyLine && trimmedLine.length > 0 ? trimmedLine : null;
}
function parseResume(txtPath) {
var lines = fs.readFileSync(txtPath, 'utf-8').split('\n');
var parsedInfo = [];
var currentCategory = null;
var isFirstNonEmptyLine = true;
lines.forEach(function (line) {
// Skip empty lines
if (!line.trim()) {
return;
}
// Check if the line is the name
var name = isName(line, isFirstNonEmptyLine);
if (name) {
parsedInfo.push({ category: 'Name', content: [name] });
isFirstNonEmptyLine = false; // Set to false after finding the first non-empty line
return;
}
// Identify section headers and set the current category
var sectionMatch = line.match(/^[A-Z\s]+$/);
if (sectionMatch) {
currentCategory = sectionMatch[0].trim();
return;
}
// Add content to the current category
if (currentCategory !== null) {
var index = parsedInfo.findIndex(function (info) { return info.category === currentCategory; });
if (index === -1) {
parsedInfo.push({ category: currentCategory, content: [line.trim()] });
}
else {
parsedInfo[index].content.push(line.trim());
}
}
});
return parsedInfo;
}
// Example usage:
var txtPath = path.join(__dirname, 'output.txt'); // Update with your actual file path
var parsedInfo = parseResume(txtPath);
console.log('Parsed Information:');
console.log(parsedInfo);
Loading