import OpenAI from 'openai';
const openai = new OpenAI({
apiKey: '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',
baseURL: 'https://integrate.api.nvidia.com/v1',
})
async function main() {
const completion = await openai.chat.completions.create({
model: "z-ai/glm5",
messages: [{"role":"user","content":""}],
temperature: 1,
top_p: 1,
max_tokens: 16384,
chat_template_kwargs: {"enable_thinking":true,"clear_thinking":false},
from openai import OpenAI
import os
import sys
_USE_COLOR = sys.stdout.isatty() and os.getenv("NO_COLOR") is None
_REASONING_COLOR = "\033[90m" if _USE_COLOR else ""
_RESET_COLOR = "\033[0m" if _USE_COLOR else ""
client = OpenAI(
base_url = "https://integrate.api.nvidia.com/v1",
api_key = "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"
)
completion = client.chat.completions.create(
model="z-ai/glm5",
messages=[{"role":"user","content":""}],
SELECT
-- pst.name AS segment_type,
MAX(CASE WHEN psi.lang_id = 1 THEN psi.name END) AS name_lang_1,
MAX(CASE WHEN psi.lang_id = 2 THEN psi.name END) AS name_lang_2,
MAX(CASE WHEN psi.lang_id = 1 THEN psi.slug END) AS slug_lang_1,
MAX(CASE WHEN psi.lang_id = 2 THEN psi.slug END) AS slug_lang_2
FROM products_segments ps
JOIN products_segments_type pst ON pst.id = ps.type
JOIN products_segments_i18n psi ON psi.product_category_id = ps.id
WHERE pst.name IN ('category', 'subcategSELECT
-- pst.name AS segment_type,
MAX(CASE WHEN psi.lang_id = 1 THEN psi.name END) AS name_lang_1,
MAX(CASE WHEN psi.lang_id = 2 THEN psi.name END) AS name_lang_2,
MAX(CASE WHEN psi.lang_id = 1 THEN psi.slug END) AS slug_lang_1,
MAX(CASE WHEN psi.lang_id = 2 THEN psi.slug END) AS slug_lang_2
FROM products_segments ps
JOIN products_segments_type pst ON pst.id = ps.type
JOIN products_segments_i18n psi ON psi.product_category_id = ps.id
WHERE pst.name IN ('category', 'subcategSELECT psi.name, ps.cat_id, ps.parent_category_id, pst.name, ps.is_active
FROM products_segments ps
JOIN products_segments_type pst ON pst.id = ps.type
JOIN products_segments_i18n psi ON psi.product_category_id = ps.id
WHERE pst.name IN ('category', 'subcategory')
AND psi.lang_id = 1
ORDER BY ps.cat_id/**
* @param {number} left
* @param {number} right
* @return {number}
*/
var countPrimeSetBits = function(left, right) {
// Precompute the only primes we care about.
// No integer in this range will have more than ~20 set bits.
const primes = new Set([2, 3, 5, 7, 11, 13, 17, 19]);
let count = 0;
// Iterate through every number in the inclusive range
for (let n = left; n <= right; n++) {
// Convert to binary and count the number of '1' bits
// Example/**
* @param {string} s
* @return {string}
*/
var makeLargestSpecial = function(s) {
// This array will hold all top-level special substrings
let subs = [];
// We'll scan the string and find balanced segments
let count = 0;
let start = 0;
for (let i = 0; i < s.length; i++) {
// '1' increases balance, '0' decreases it
if (s[i] === '1') count++;
else count--;
// When count returns to 0, we found a complete special substring
if (import { useEffect, useState } from "react"
import { User } from "./User"
export default function App() {
const [users, setUsers] = useState([])
const [error, setError] = useState(null)
const [status, setStatus] = useState("idle")
useEffect(() => {
setStatus("loading")
setUsers([])
setError(null)
const controller = new AbortController()
fetch("https://jsonplaceholder.typicode.com/users", {
signal: controller.signal,
})
.then(res => // ==UserScript==
// @name hribi.net gallery arrow keys
// @namespace Violentmonkey Scripts
// @match https://www.hribi.net/*
// @grant none
// @version 1.0
// @author -
// @description 5/3/2025, 7:04:37 PM
// ==/UserScript==
const backButton = document.querySelector('.slikanazaj > a');
const forwardButton = document.querySelector('.slikanaprej > div:not(.slikanazaj2) > a');
document.addEventListener('keydown', function(event) {
if (event.key === 'ArrowLeft' && b./install dotfiles nvim # Just install "dotfiles" and "nvim" stuff.
./install dotfiles # Just install "dotfiles".
./install dotfiles --step # Prompt for confirmation at each step.
./install dotfiles --check # Do a dry-run, showing what would be changed.
./install # Install everything.
./install ^homebrew # Install everything except for the "homebrew" aspect.
./install --help # Lists all aspects, descriptions, options.function Add-CMSoftwareUpdateFilePath {
# Pipe Get-CMSoftwareUpdate to this function
$CMSoftwareUpdate = @($input)
$sitecode = (Get-CimInstance -ClassName SMS_Authority -Namespace root\ccm).Name.Split(':')[1]
$NameSpace = "root\SMS\site_$sitecode"
$UpdateCIIDs = $CMSoftwareUpdate.CI_ID
if ($UpdateCIIDs.Count -eq 0 ) { Write-Warning "No updates returned."; return }
foreach ($UpdateCIID In $UpdateCIIDs) {
$UpdateContent = Get-CimInstance -Namespace$cmtrace = "C:\Windows\CCM\CMTrace.exe"
cmd /c assoc .log=CMTrace.LogFile
cmd /c assoc .lo_=CMTrace.LogFile
cmd /c ftype CMTrace.LogFile="$cmtrace" "%1"
# Introduction
- Add your project logo.
- Write a short introduction to the project.
- If you are using badges, add them here.
## :ledger: Index
- [About](#beginner-about)
- [Usage](#zap-usage)
- [Installation](#electric_plug-installation)
- [Commands](#package-commands)
- [Development](#wrench-development)
- [Pre-Requisites](#notebook-pre-requisites)
- [Developmen Environment](#nut_and_bolt-development-environment)
- [File Structure](#file_folder-file-structure)
- [Build](#hammer-/**
* @param {string} s
* @return {number}
*/
var countBinarySubstrings = function(s) {
// Step 1: We'll store the lengths of consecutive groups.
// Example: "0011100" -> [2, 3, 2]
let groups = [];
let count = 1; // count the current run length
// Step 2: Build the groups array
for (let i = 1; i < s.length; i++) {
if (s[i] === s[i - 1]) {
// same character → extend current group
count++;
} else {
// character changed