Skip to content

Instantly share code, notes, and snippets.

View poul-kg's full-sized avatar

Pavel Kostenko poul-kg

View GitHub Profile
@poul-kg
poul-kg / messages-100.json
Last active February 20, 2026 08:32
messages-100.json
[
{"title": "Project kickoff discussion", "from": [{"address": "alice@techstart.com", "name": "Alice Johnson"}], "to": [{"address": "bob@stitch.ai", "name": "Bob"}], "bodyHtml": "<p>Hi Bob, I wanted to reach out regarding the upcoming project. I think we should schedule a meeting this week to align on the scope and timeline. I've been reviewing the requirements and have some initial thoughts on the architecture.</p><p>Looking forward to collaborating with you on this. Let me know your availability and we can get this rolling.</p>", "state": "RECEIVED", "unread": true},
{"title": "Quick question about the API", "from": [{"address": "charlie@devteam.io", "name": "Charlie Davis"}], "to": [{"address": "bob@stitch.ai", "name": "Bob"}], "bodyHtml": "<p>Hi Bob, I was reviewing the API documentation and had a question about the authentication flow. Can you clarify how the token refresh mechanism is supposed to work?</p><p>Also, do you have any performance benchmarks for the endpoint under load? I want to make sur
@poul-kg
poul-kg / demo-startup-50.json
Created February 20, 2026 08:14
demo-startup-50.json
[
{
"title": "Q1 Architecture Review - Scaling Plan",
"from": {"address": "sarah.chen@startup.io", "name": "Sarah Chen"},
"to": [{"address": "cto@startup.io", "name": "CTO"}],
"bodyHtml": "<p>Hi,</p><p>I've completed the Q1 architecture review. We need to discuss the scaling strategy for our database layer before we hit 10k concurrent users. Can we sync this week?</p><p>Key findings attached in the design doc.</p>",
"date": "2026-02-19T14:30:00Z",
"direction": "INCOMING",
"state": "RECEIVED"
},
@poul-kg
poul-kg / bot-luis-timezone-offset.js
Created November 14, 2018 09:30
MS BotFramework LUIS timezoneOffset
/**
* How to change timestamp in ms botframework on every request to LUIS by the bot
*/
const builder = require('botbuilder');
/**
* Create custom LUIS recognizer which can change timezoneOffset in LUIS URL to another offset if we have
* timezone offset somewhere in the session
*
@poul-kg
poul-kg / valet.conf
Last active July 2, 2025 19:35
CORS Rules for Laravel Valet Nginx
# To enable CORS you should add lines with CORS rules below to your valet.conf file
# Find the file /usr/local/etc/nginx/valet/valet.conf - this is Valet conf for Nginx
# of try to execute `locate valet.conf` and find the `valet.coinf` in `nginx` subdirectory
# after you edit your valet.conf do not forget to execute `valet restart`
server {
listen 80 default_server;
root /;
charset utf-8;
client_max_body_size 128M;
@poul-kg
poul-kg / life-ai-app-privacy-policy
Created May 16, 2017 11:55
Life AI App Privacy Policy
# Life AI Privacy Policy
* This is a demo app for testing some concepts
* we do not record user identity
* we need RECORD_AUDIO permission to be able to use voice recognition for entering text in the chat
* user interacts with chat bot
* no data is shared with 3rd parties
* questions user type in the chat UI are recorded and can be used to train/improve Natural Language Classifier we use.
@poul-kg
poul-kg / watson-page-response.twig
Created December 1, 2016 12:03
Watson Page Response in Twig
{% set s3 = 'https://s3-us-west-1.amazonaws.com/neon-global/watson' %}
{% set paragraph1 = "22 CityLink is bringing an innovative approach to building smart cities, starting from the ground-up. At the crossroads of efficiency and sustainability, our state-of-the-art platform provides an environment where people, businesses, and governments can flourish. Our holistic approach combines the power of artificial intelligence and machine learning to tailor and adapt to the needs of each citizen, while providing businesses and governments the information needed to create a world-class experience." %}
{% set paragraph2 = "Welcome to 22 CityLink. The Future of Living." %}
{% set page = {
layout: 'About_Us_Layout',
title: "Who are we?",
text: [paragraph1, paragraph2],
imageUrl: s3 ~ "/ipad-color-city-2.png",
backgroundImageUrl: s3 ~ "/assets/img/img-31.jpg"
@poul-kg
poul-kg / semantic-ui-twig-template.html
Created December 1, 2016 12:01
Semantic UI Twig Template
<div class="bg">
<div class="bg-img" style="background-image: url({{page.backgroundImageUrl}});"></div>
</div>
<div class="ui two column stackable grid container">
<!-- Text Column -->
<div class="column">
<h1>{{page.title}}</h1>
{% if page.text is iterable %}
{% for paragraph in page.text %}
<p>{{paragraph|raw}}</p>
@poul-kg
poul-kg / teamcity
Created November 11, 2015 09:33
TeamCity startup script for Ubuntu 14.04 on AWS
#!/bin/sh
# /etc/init.d/teamcity
# This will start TeamCity & Default build agent on system startup as ubuntu user
# To run it on every system startup, execute:
# sudo update-rc.d teamcity defaults
case "$1" in
start)
echo "Starting TeamCity"
start-stop-daemon --start --chuid ubuntu:ubuntu --quiet --exec /home/ubuntu/distr/TeamCity/bin/runAll.sh start > /dev/null
@poul-kg
poul-kg / buildagent
Last active November 11, 2015 09:33
TeamCity build agent startup - Ubuntu 14.04 on AWS
#!/bin/sh
# /etc/init.d/buildagent
# # This will start TeamCity build agent on system startup as ubuntu user
# To run it on every system startup, execute:
# sudo update-rc.d buildagent defaults
case "$1" in
start)
echo "Starting TeamCity build agent "
start-stop-daemon --start --chuid ubuntu:ubuntu --quiet --exec /home/ubuntu/BuildAgent/bin/agent.sh start > /dev/null