Sobes.tech

What types of chunking (text segmentation) exist?

Middle+
205

import psycopg2 def save_prediction(text: str, result: str): conn = psycopg2.connect("host=db user=app password=secret dbname=ml") cur = conn.cursor() cur.execute( "INSERT INTO predictions (input, output) VALUES (%s, %s)", (text, result) ) conn.commit() cur.close()

Middle+
163

Why are microservices popular?

Middle+
153

What is the difference between synchronous and asynchronous programming?

Middle+
153

Name the main message brokers and their differences.

Middle+
144

from src import load_model @app.post("/classify") async def classify(request: dict): text = request["text"] model = load_model("classifier_v1") prediction = model.predict([text]) return {"label": prediction}

Middle+
139

What is the difference between an image and a container in Docker?

Middle+
136

Are you familiar with Kubernetes? What is it?

Middle+
132

FROM python:3.11-slim WORKDIR /app COPY . RUN pip install -r requirements.txt RUN useradd -m appuser USER appuser EXPOSE 8000 CMD ["python", "main.py"]

Middle+
129

What is a fixture in pytest?

Middle+
129

What is a neural network from a mathematical point of view? Which branch of mathematics is fundamental for ML?

Middle+
128

import aiohttp import asyncio async def fetch_all_tickets(self, ticket_ids: list, max_concurrent_requests: int =10): semaphore = asyncio.Semaphore(max_concurrent_requests) async with aiohttp.ClientSession() as session: tasks = [self._get_ticket(ticket_id, session, semaphore) for ticket_id in ticket_ids] tickets = [] for task in tasks: ticket = await task if ticket is not None: tickets.append(ticket) return tickets

Middle+
126

What are your career plans for 3-5 years?

Middle+
126

Name four principles of OOP.

Middle+
124

What is the semantic difference between the GET and POST methods?

Middle+
123

What technologies are you interested in besides Python?

Middle+
122

async def call_provider(text: str) -> str: async with aiohttp.ClientSession() as session: async with session.post( "[link] json={"text": text} ) as resp: return await resp.json()

Middle+
121

How do you feel about routine tasks like refactoring legacy code?

Middle+
119

What is GIL (Global Interpreter Lock)?

Middle+
106
/2