Talent.com
Facilities Engineer
Facilities EngineervTech Solution • Washington, DC, United States
Facilities Engineer

Facilities Engineer

vTech Solution • Washington, DC, United States
4 days ago
Job type
  • Full-time
  • Quick Apply
Job description

Job Summary : #src / main.py

import os

import json

import re

import PyPDF2

import docx

import requests

import pdfplumber

import docx

import hashlib

import io

import zipfile

import xml.etree.ElementTree as ET

import openpyxl

import hashlib

import unicodedata

import regex

from typing import Pattern

from flask import Flask, jsonify, request

from google.cloud import firestore

from flask_cors import CORS

from datetime import datetime, timezone

from dotenv import load_dotenv

import firebase_admin

from firebase_admin import credentials, firestore, storage

from bs4 import BeautifulSoup # for URL text extraction

import PyPDF2

import unicodedata, regex, uuid

from crew_ai.document_crew import run_analysis

import asyncio

from concurrent.futures import ThreadPoolExecutor

import uuid

from urllib.parse import unquote

from threading import Thread

from itertools import zip_longest

from crewai import Crew

from crew_ai.agent import capture

from crew_ai.document_task import capture_task

from crew_ai.document_task import extract_orgname # adjust import if needed

import regex

import unicodedata

from typing import Union

import unicodedata

# Load environment variables

load_dotenv()

# Initialize Flask app

app = Flask(__name__) # MUST come first

# Configure CORS

allowed_origins = os.getenv("ALLOWED_ORIGINS", "

  • ") # e.g. "http : / / localhost : 3000"

CORS(app, resources={r" /

  • " : {"origins" : allowed_origins}})
  • service_account_info = json.loads(os.getenv("FIREBASE_SERVICE_ACCOUNT"))

    cred = credentials.Certificate(service_account_info)

    firebase_admin.initialize_app(cred, {

    "storageBucket" : service_account_info.get("storageBucket")

    })

    db = firestore.client()

    bucket = storage.bucket()

    print(f" Firebase initialized with bucket : {bucket.name}")

    # Azure OpenAI Setup

    AZURE_API_KEY = os.getenv("AZURE_OPENAI_API_KEY")

    AZURE_API_BASE = os.getenv("AZURE_OPENAI_API_BASE")

    AZURE_API_VERSION = os.getenv("AZURE_OPENAI_API_VERSION")

    AZURE_DEPLOYMENT_NAME = os.getenv("AZURE_OPENAI_DEPLOYMENT_NAME")

    AZURE_API_URL = f"{AZURE_API_BASE} / openai / deployments / {AZURE_DEPLOYMENT_NAME} / chat / completions?api-version={AZURE_API_VERSION}"

    def extract_pdf_text(content) :

    text = ""

    try :

    with pdfplumber.open(io.BytesIO(content)) as pdf :

    for page in pdf.pages :

    page_text = page.extract_text()

    if page_text :

    text += page_text + "

    except Exception as e :

    print(" PDF parsing error : " + str(e))

    return text

    def extract_docx_text(content) :

    text = ""

    try :

    doc = docx.Document(io.BytesIO(content))

    text = "

    ".join([p.text for p in doc.paragraphs])

    for table in doc.tables :

    for row in table.rows :

    text += "

    " + " ".join(cell.text for cell in row.cells)

    except Exception as e :

    print(" DOCX parsing error : " + str(e))

    return text

    def extract_txt_text(content) :

    try :

    return content.decode("utf-8", errors="ignore")

    except Exception as e :

    print(" TXT decoding error : " + str(e))

    return ""

    def extract_text_by_type(filename, content) :

    filename_lower = filename.lower()

    if filename_lower.endswith(".pdf") :

    return extract_pdf_text(content)

    if filename_lower.endswith(".docx") :

    return extract_docx_text(content)

    if filename_lower.endswith(".txt") :

    return extract_txt_text(content)

    if filename_lower.endswith(".pptx") :

    return extract_pptx_text(content)

    if filename_lower.endswith(".xlsx") :

    return extract_xlsx_text(content)

    print(f" Unsupported file type : {filename}")

    return ""

    def get_files_from_firebase_folder(folder_name) :

    """

    Reads all files from Firebase Storage folder, extracts text, and returns as a single string.

    """

    texts = []

    try :

    blobs = list(bucket.list_blobs(prefix=f"Upload / {folder_name} / "))

    print(f"

    Create a job alert for this search

    Engineer • Washington, DC, United States

    Related jobs
    Systems Engineer (Facilities & Real Estate)

    Systems Engineer (Facilities & Real Estate)

    InsideHigherEd • Baltimore, Maryland, United States
    Full-time
    Conducts systems performance evaluations, monitoring, patch management and security evaluations.Analyzes user needs in various computer environments (including but not limited to mainframe, Windows...Show more
    Last updated: 29 days ago • Promoted
    Facilities Project Specialist

    Facilities Project Specialist

    Arlington County (Virginia, USA) • Washington, DC, US
    Full-time
    Construction, Eng & Inspection Services.Job Category : Construction, Eng & Inspection Svcs.Posting Date : 08 / 22 / 2025, 04 : 00 AM. Locations : 1400 N Uhle St, Arlington, VA, 22201, US (Hybrid).Show more
    Last updated: 30+ days ago • Promoted
    Classified Facility Systems Engineer

    Classified Facility Systems Engineer

    Enabled Intelligence • Falls Church, VA, USA
    Full-time
    Quick Apply
    Classified Facility Systems Engineer.AI solutions to help our government and commercial customers effectively deploy reliable and unbiased artificial intelligence technologies.Every Enabled solutio...Show more
    Last updated: 30+ days ago
    Cybersecurity Facilities Engineer - Subject Matter Expert

    Cybersecurity Facilities Engineer - Subject Matter Expert

    MORI Associates • Washington, DC, United States
    Full-time
    Take your career to new heights.Come join us at MORI Associates and help us support the most exciting projects at the Defense Department. As a Cybersecurity Facilities Subject Expert you will be par...Show more
    Last updated: 30+ days ago • Promoted
    Facilities Mechanical Engineer

    Facilities Mechanical Engineer

    Leidos Inc • Springfield, VA, United States
    Full-time
    Facilities Mechanical Engineer.TS / SCI with the ability to pass a polygraph.Leidos is seeking an experienced Facilities Mechanical Engineer to lead the design, maintenance, and configuration managem...Show more
    Last updated: 10 days ago • Promoted
    Facilities Lead

    Facilities Lead

    Barry's • Washington, DC, US
    Full-time +1
    The Client Facilities Lead is essential to the operation of our studios.They serve as a maintenance leader overseeing all maintenance operations across the studio. They will collaborate with cross-f...Show more
    Last updated: 30+ days ago • Promoted
    Facilities Supervisor

    Facilities Supervisor

    Quest Diagnostics • Chantilly, VA, US
    Full-time
    Focus on the core content of the job post, removing any extra metadata, navigation mentions, and redundant headers.Keep the formatting beautiful and high signal to noise ratio.Show more
    Last updated: 5 days ago • Promoted
    Facilities Engineering Manager

    Facilities Engineering Manager

    Quest Diagnostics • Chantilly, VA, US
    Full-time
    Focus on the core content of the job post, removing any unnecessary metadata, navigation links, and extraneous details.The goal is to present a clean, beautiful, and high signal-to-noise ratio vers...Show more
    Last updated: 5 days ago • Promoted
    Facilities - Contractor - L4

    Facilities - Contractor - L4

    Innova Solutions • Columbia, MD,Maryland,United States
    Full-time
    Quick Apply
    A client of Innova Solutions is immediately hiring a.Position Type : Full time Contract, Possible Contract to Hire.Develop and implement space planning strategies that accommodate current and future...Show more
    Last updated: 30+ days ago
    Senior Facilities Architect

    Senior Facilities Architect

    Leidos Inc • Chantilly, VA, United States
    Full-time
    We are seeking a skilled Senior Facilities Architect licensed professional who leads and manages architectural projects from design to completion, ensuring they meet both aesthetic and functional r...Show more
    Last updated: 30+ days ago • Promoted
    Facilities Support Specialist

    Facilities Support Specialist

    Clearance Jobs • Quantico, VA, US
    Full-time
    Mantech seeks a motivated, career and customer-oriented Facilities Support Specialist to join our team in Quantico, VA.This position requires expertise to support the receipt and management of all ...Show more
    Last updated: 30+ days ago • Promoted
    Facilities Architect

    Facilities Architect

    Leidos Inc • Springfield, VA, United States
    Full-time
    We are seeking a skilled Facilities Architect licensed professional who leads and manages architectural projects from design to completion, ensuring they meet both aesthetic and functional requirem...Show more
    Last updated: 30+ days ago • Promoted
    Director Facilities Engineering

    Director Facilities Engineering

    Virginia Hospital Center • Washington, DC, US
    Full-time
    Director Facilities Engineering.Responsible for the planning, organization, staffing, control and management of the Facilities Engineering Department. Responsible for establishing, updating and moni...Show more
    Last updated: 10 days ago • Promoted
    Facilities Manager

    Facilities Manager

    GSK • Rockville, MD, US
    Full-time
    At GSK Rockville, we are looking for a Facilities Manager who will be responsible for providing support site wide for utility systems, routine and preventative maintenance and repairs for all equip...Show more
    Last updated: 30+ days ago • Promoted
    Facilities Engineer with Min 10yrs exp (Phone interview) (100% ONSITE_Only Local to DMV Area)

    Facilities Engineer with Min 10yrs exp (Phone interview) (100% ONSITE_Only Local to DMV Area)

    Advanced American Technologies, Inc • Washington, DC, United States
    Full-time
    Quick Apply
    MsoNoSpacing"> We are looking for Facilities Engineer (Min 6-10+ Yrs.Exp) ONSITE ( Phone Interview ) .POSITION DESCRI...Show more
    Last updated: 3 days ago
    Facilities Engineer

    Facilities Engineer

    Rishabh RPO • Washington, DC, United States
    Full-time
    Quick Apply
    MsoNoSpacing"> Position Title & Code : Facilities Engineer Location : Washington DC &l...Show more
    Last updated: 5 days ago
    Facilities Administrator

    Facilities Administrator

    Shimadzu Scientific Instruments • Columbia, MD, United States
    Full-time
    Established in 1975, Shimadzu Scientific Instruments is one of the largest suppliers of analytical instrumentation, physical testing, and environmental monitoring systems in the world.Ground-breaki...Show more
    Last updated: 12 days ago • Promoted
    Systems Engineer (Facilities & Real Estate)

    Systems Engineer (Facilities & Real Estate)

    Johns Hopkins University • Baltimore, MD, United States
    Full-time
    Conducts systems performance evaluations, monitoring, patch management and security evaluations.Analyzes user needs in various computer environments (including but not limited to mainframe, Windows...Show more
    Last updated: 30+ days ago • Promoted