並び順

ブックマーク数

期間指定

  • から
  • まで

1 - 40 件 / 48件

新着順 人気順

python range for float numbersの検索結果1 - 40 件 / 48件

  • OpenAIのプロンプトジェネレーターで至高のプロンプトを生成する - Taste of Tech Topics

    こんにちはイワツカです。 食欲の秋ということでサツマイモやキノコが美味しい季節ですね。 さて今回は、生成AIを使おうと思ってもプロンプトの書き方がよく分からず、生成AIから思ったような回答を得られない...なんて方におススメのOpenAIのプロンプトジェネレーター機能を紹介します。 1. プロンプトジェネレーターとは 使い方 2. ユースケースごとのプロンプトと結果比較 Pythonコードのリファクタリング プロンプトジェネレーターを使わない場合 プロンプトジェネレーターを使う場合 API設計 プロンプトジェネレーターを使わない場合 プロンプトジェネレーターを使う場合 ブログ作成 プロンプトジェネレーターを使わない場合 プロンプトジェネレーターを使う場合 3. まとめ 1. プロンプトジェネレーターとは プロンプトジェネレーターとは、その名の通り、AIに対する指示文(プロンプト)を自動的に

      OpenAIのプロンプトジェネレーターで至高のプロンプトを生成する - Taste of Tech Topics
    • GPT-5 の新パラメータとツール|npaka

      以下の記事が面白かったので、簡単にまとめました。 ・GPT-5 New Params and Tools - OpenAI Cookbook 1. verbosity1-1. 概要「verbosity」は、出力トークン数を調節できます。 ・low : 簡潔なUX、簡潔な文章 ・medium (デフォルト) : バランスの取れた詳細 ・high : 詳細な情報。監査、教育、引き継ぎに最適 1-2. verbosityの効果の確認プロンプトを一定に保ったまま、「verbosity」を変更することで、効果を確認できます。 response = client.responses.create( model="gpt-5", input="人生、宇宙、そして万物に関する究極の問いに対する答えは何でしょうか?", text={ "verbosity": "low" } ) print(response

        GPT-5 の新パラメータとツール|npaka
      • 新しくプログラミング言語を作る際に数値型をどうするべきか

        この記事は、新しくプログラミング言語を設計する際に数値型をどうするべきかについて、私の持論をまとめたものです。 数の体系 JavaScript(BigInt以前)やLua(〜5.2)などは唯一の数値型が浮動小数点数型で、整数も実数も同じ「number」型で表現します。ミニマルな言語を作るのならそういう設計もアリかもしれませんが、ネイティブコンパイルも視野に入る実用的な言語を作るなら整数と実数を一緒くたにする設計はやめた方が良いと思います。 特に、JavaScriptにコンパイルする言語を作るからと言って、数値型の設計まで真似る必要はありません。 整数を浮動小数点数で表現すると、思わぬ性能低下の要因になったりします。最近(2023年2月)、次のツイートが話題になりました: これは正のゼロと負のゼロが値として区別され、正のゼロは内部的に整数扱いされるのに対し負のゼロはそうではないことによるもの

          新しくプログラミング言語を作る際に数値型をどうするべきか
        • GPT in 60 Lines of NumPy | Jay Mody

          January 30, 2023 In this post, we'll implement a GPT from scratch in just 60 lines of numpy. We'll then load the trained GPT-2 model weights released by OpenAI into our implementation and generate some text. Note: This post assumes familiarity with Python, NumPy, and some basic experience with neural networks. This implementation is for educational purposes, so it's missing lots of features/improv

          • The Scary Thing About Automating Deploys - Engineering at Slack

            Most of Slack runs on a monolithic service simply called “The Webapp”. It’s big – hundreds of developers create hundreds of changes every week. Deploying at this scale is a unique challenge. When people talk about continuous deployment, they’re often thinking about deploying to systems as soon as changes are ready. They talk about microservices and 2-pizza teams (~8 people). But what does continuo

            • 缶つぶし機とソフトウェア移行技術 - Refactoring to Rust の読書感想文 - じゃあ、おうちで学べる

              はじめに ——あるいは、「知っている」と「理解している」の間 Rustのことは、知っていた。学習もしていた。実務でも使っていた。 でも、それは知っているつもりだった。 知ってるつもり 無知の科学 (ハヤカワ文庫NF) 作者:スティーブン スローマン,フィリップ ファーンバック早川書房Amazon 日々Rustで開発し、BoxとRcとArcを使い分け、tokio::spawnでタスクを生成し、?演算子を当たり前のように書いている。FFI?PyO3使えばいいでしょ。WebAssembly?wasm-bindgenがあるじゃない。技術的には、確かに「使える」レベルにはあった。 でも、心のどこかで感じていた違和感があった。 オートバイのエンジンを分解できる人と、エンジンが動く原理を理解している人は違う。コードが動くことと、なぜそう書くべきかを理解することも違う。私は前者だった。メカニックではあった

                缶つぶし機とソフトウェア移行技術 - Refactoring to Rust の読書感想文 - じゃあ、おうちで学べる
              • Optimizing your LLM in production

                Note: This blog post is also available as a documentation page on Transformers. Large Language Models (LLMs) such as GPT3/4, Falcon, and LLama are rapidly advancing in their ability to tackle human-centric tasks, establishing themselves as essential tools in modern knowledge-based industries. Deploying these models in real-world tasks remains challenging, however: To exhibit near-human text unders

                  Optimizing your LLM in production
                • Gamedev in Lisp. Part 1: ECS and Metalinguistic Abstraction - cl-fast-ecs by Andrew

                  Gamedev in Lisp. Part 1: ECS and Metalinguistic Abstraction In this series of tutorials, we will delve into creating simple 2D games in Common Lisp. The result of the first part will be a development environment setup and a basic simulation displaying a 2D scene with a large number of physical objects. It is assumed that the reader is familiar with some high-level programming language, has a gener

                    Gamedev in Lisp. Part 1: ECS and Metalinguistic Abstraction - cl-fast-ecs by Andrew
                  • Golang Mini Reference 2022: A Quick Guide to the Modern Go Programming Language (REVIEW COPY)

                    Golang Mini Reference 2022 A Quick Guide to the Modern Go Programming Language (REVIEW COPY) Harry Yoon Version 0.9.0, 2022-08-24 REVIEW COPY This is review copy, not to be shared or distributed to others. Please forward any feedback or comments to the author. • feedback@codingbookspress.com The book is tentatively scheduled to be published on September 14th, 2022. We hope that when the release da

                    • CohereLabs/c4ai-command-r-plus · Hugging Face

                      ","chat_template":[{"name":"default","template":"{{ bos_token }}{% if messages[0]['role'] == 'system' %}{% set loop_messages = messages[1:] %}{% set system_message = messages[0]['content'] %}{% elif false == true %}{% set loop_messages = messages %}{% set system_message = 'You are Command-R, a brilliant, sophisticated, AI-assistant trained to assist human users by providing thorough responses. You

                        CohereLabs/c4ai-command-r-plus · Hugging Face
                      • はじめての自然言語処理 Fusion-In-Decoder でクイズに答えるモデルを作る | オブジェクトの広場

                        今回は Fusion-In-Decoder を使ってクイズに答えるモデルを作ります。以前から Wikipedia 等の外部情報を参照できるテキスト生成モデルを試してみたいと思っていました。Fusion-In-Decoder の発表は 2020 年なので少し前のモデルですが、T5 ベースで手軽に試せるサイズ感ですので、日本語で試してみましょう。 1. はじめに 今回紹介する Fusion-In-Decoder(以下、FiD )1 は Meta AI (当時は Facebook AI Research) が発表した Open Domain question Answering タスクを解くテキスト生成モデルです。 じつは、以前から外部情報を参照できるテキスト生成モデルを試してみたくて2、 Google の RETRO3 の論文を読んでたんです。 なのですが、外部情報のサイズ感が 1000 B

                          はじめての自然言語処理 Fusion-In-Decoder でクイズに答えるモデルを作る | オブジェクトの広場
                        • 0.8.0 Release Notes ⚡ The Zig Programming Language

                          Tier 4 Support § Support for these targets is entirely experimental. If this target is provided by LLVM, LLVM may have the target as an experimental target, which means that you need to use Zig-provided binaries for the target to be available, or build LLVM from source with special configure flags. zig targets will display the target if it is available. This target may be considered deprecated by

                          • So You Want To Remove The GVL?

                            I want to write a post about Pitchfork, explaining where it comes from, why it is like it is, and how I see its future. But before I can get to that, I think I need to share my mental model on a few things, in this case, Ruby’s GVL. For quite a long time, it has been said that Rails applications are mostly IO-bound, hence Ruby’s GVL isn’t that big of a deal and that has influenced the design of so

                            • Solving Quantitative Reasoning Problems With Language Models

                              Solving Quantitative Reasoning Problems with Language Models Aitor Lewkowycz∗, Anders Andreassen†, David Dohan†, Ethan Dyer†, Henryk Michalewski†, Vinay Ramasesh†, Ambrose Slone, Cem Anil, Imanol Schlag, Theo Gutman-Solo, Yuhuai Wu, Behnam Neyshabur∗, Guy Gur-Ari∗, and Vedant Misra∗ Google Research Abstract Language models have achieved remarkable performance on a wide range of tasks that require

                              • ​Getting Started with Python

                                Python is a powerful programming language that provides many packages that we can use. Using the versatile Python programming language, we can develop the following: AutomationDesktop applicationAndroidWebIoT home automationData Science and the list goes on.In this article, our primary focus will be knowing how to start learning Python and the essentials required to be a data scientist. Below is t

                                  ​Getting Started with Python
                                • はじめての自然言語処理 Hugging Face Transformers で T5 を使ってみる | オブジェクトの広場

                                  前回が分量的にやたらと重かったので、今回はその反省(反動?)を踏まえて軽い感じでいってみます。第7回で紹介した T5 ですが Hugging Face の Transformers でもサポートされてますので、その使用方法をご紹介したいと思います。 1. はじめに 今回は久しぶりに T5 の話です。T5 に関しては第7回、第8回で一度紹介しているので、未読の方は記事に目を通してから戻ってきて頂けると、より理解がしやすいと思います。 さて、 T5 ですが Google のオリジナルコード(以下 “t5"と記述)1は敷居が高いと感じる方もいらっしゃるのではないでしょうか。 Estimator API ベースのコードや gin による設定など慣れていないと、とっつきにくいのではないかと思います。 そこで今回は Hugging Face の Transformers 2を使って T5 を動かす方法

                                    はじめての自然言語処理 Hugging Face Transformers で T5 を使ってみる | オブジェクトの広場
                                  • 0.10.0 Release Notes ⚡ The Zig Programming Language

                                    Tier 4 Support § Support for these targets is entirely experimental. If this target is provided by LLVM, LLVM may have the target as an experimental target, which means that you need to use Zig-provided binaries for the target to be available, or build LLVM from source with special configure flags. zig targets will display the target if it is available. This target may be considered deprecated by

                                    • The Art and Mathematics of Genji-Kō - OranLooney.com

                                      The Art and Mathematics of Genji-Kō by Oran Looney November 26, 2024 Math Visualization History Python You might think it’s unlikely for any interesting mathematics to arise from incense appreciation, but that’s only because you’re unfamiliar with the peculiar character of Muromachi (室町) era Japanese nobles. There has never been a group of people, in any time or place, who were so driven to displa

                                      • Accelerate Python code 100x by import taichi as ti | Taichi Docs

                                        Python has become the most popular language in many rapidly evolving sectors, such as deep learning and data sciences. Yet its easy readability comes at the cost of performance. Of course, we all complain about program performance from time to time, and Python should certainly not take all the blame. Still, it's fair to say that Python's nature as an interpreted language does not help, especially

                                        • Parquet and Postgres in the Data Lake | Crunchy Data Blog

                                          Interested in Spatial analytics? You can now connect Postgres and PostGIS to CSV, JSON, Parquet / GeoParquet, Iceberg, and more with Crunchy Data Warehouse. Static Data is DifferentA couple weeks ago, I came across a blog from Retool on their experience migrating a 4TB database. They put in place some good procedures and managed a successful migration, but the whole experience was complicated by t

                                            Parquet and Postgres in the Data Lake | Crunchy Data Blog
                                          • prompts.chat

                                            Welcome to the “Awesome ChatGPT Prompts” repository! While this collection was originally created for ChatGPT, these prompts work great with other AI models like Claude, Gemini, Hugging Face Chat, Llama, Mistral, and more. ChatGPT is a web interface created by OpenAI that provides access to their GPT (Generative Pre-trained Transformer) language models. The underlying models, like GPT-4o and GPT-o

                                            • The Best GPUs for Deep Learning in 2023 — An In-depth Analysis

                                              Deep learning is a field with intense computational requirements, and your choice of GPU will fundamentally determine your deep learning experience. But what features are important if you want to buy a new GPU? GPU RAM, cores, tensor cores, caches? How to make a cost-efficient choice? This blog post will delve into these questions, tackle common misconceptions, give you an intuitive understanding

                                                The Best GPUs for Deep Learning in 2023 — An In-depth Analysis
                                              • How it became like this? Ruby Range class

                                                Understanding the core class design and usage via its evolution Years ago, my studies into the Ruby Evolution started with the persuasion that mastering the programming language to express one’s intentions clearly and efficiently may grow significantly by understanding how it evolved and what intentions were put behind its various elements. Moving back through the history of a change of some eleme

                                                  How it became like this? Ruby Range class
                                                • xvw.lol - Why I chose OCaml as my primary language

                                                  This article is a translation, the original version is available here. I started using the OCaml language regularly around 2012, and since then, my interest and enthusiasm for this language have only grown. It has become my preferred choice for almost all my personal projects, and it has also influenced my professional choices. Since 2014, I have been actively participating in public conferences d

                                                  • Mastering Customer Segmentation with LLM | Towards Data Science

                                                    Unlock advanced customer segmentation techniques using LLMs, and improve your clustering models with advanced techniques Content Table · Intro · Data · Method 1: Kmeans · Method 2: K-Prototype · Method 3: LLM + Kmeans · Conclusion Intro A customer segmentation project can be approached in multiple ways. In this article I will teach you advanced techniques, not only to define the clusters, but to a

                                                      Mastering Customer Segmentation with LLM | Towards Data Science
                                                    • What's New in Emacs 28.1?

                                                      Try Mastering Emacs for free! Are you struggling with the basics? Have you mastered movement and editing yet? When you have read Mastering Emacs you will understand Emacs. It’s that time again: there’s a new major version of Emacs and, with it, a treasure trove of new features and changes. Notable features include the formal inclusion of native compilation, a technique that will greatly speed up y

                                                      • Vim9 script for Python Developers · GitHub

                                                        vim9script4pythondevelopers.md Vim9 script for Python Developers Vim9 script�Vim script��������������������������������������������������系��� def������義����������Vim script��vim9script�����使����������(vim9script���

                                                          Vim9 script for Python Developers · GitHub
                                                        • Type Parameters Proposal

                                                          Ian Lance Taylor Robert Griesemer August 20, 2021 StatusThis is the design for adding generic programming using type parameters to the Go language. This design has been proposed and accepted as a future language change. We currently expect that this change will be available in the Go 1.18 release in early 2022. AbstractWe suggest extending the Go language to add optional type parameters to type an

                                                          • Prompt flowの良いところ、難しいところ ── 使ってみてわかった! - SmartHR Tech Blog

                                                            こんにちは!SmartHRでAIプロダクト開発をしている@nukosukeです。 近年、様々な企業でLLMを使ったアプリケーション開発を模索しています。 SmartHRもその1つで、AIプロダクト開発チームではLLMを使ったプロダクトを模索しています。 LLM関連のツールは枚挙にいとまがないほどありますが、AIプロダクト開発チームではPrompt flowというツールを使っていました。 今回は、AIプロダクト開発チームでのPrompt flowを使って、LLMにアプリケーションを評価させるLLM as a Judgeを使った経験を下記のラインナップで紹介します。 注意事項 Prompt flowとは? AIプロダクト開発チームでのPrompt flowの使い方 Prompt flowの良いところ タスクをYAMLで書くとよしなに色々してくれる LLMの処理が簡潔に書ける タスクの処理を追跡

                                                              Prompt flowの良いところ、難しいところ ── 使ってみてわかった! - SmartHR Tech Blog
                                                            • 同時タイムラプスのGUIをpythonでつくってみた - Qiita

                                                              import PySimpleGUI as sg import datetime import time import os import numpy as np import cv2 import glob from time import sleep mport schedule import mojimoji import sys # class def cam_2(create_directory1,create_directory2): # global create_directory1 cap1 = cv2.VideoCapture(1,cv2.CAP_DSHOW) time.sleep(1) cap1.set(cv2.CAP_PROP_EXPOSURE,-6) ret1, frame1 = cap1.read() print(ret1) if ret1 == False:

                                                                同時タイムラプスのGUIをpythonでつくってみた - Qiita
                                                              • Laurence Tratt: Automatic Video Editing

                                                                Amongst the many consequences of COVID-19 has been the suspension of in-person talks: suddenly, people like me have had to think about how to produce prerecorded videos. In this article I’m going to explain what I’ve come to understand about video recording and the “automatic video editing” technique I’ve used for videos such as Virtual Machine Warmup Blows Hot and Cold. To give you an idea of how

                                                                • Basic facts about GPUs

                                                                  Basic facts about GPUs last updated: 2025-06-18 I’ve been trying to get a better sense of how GPUs work. I’ve read a lot online, but the following posts were particularly helpful: Making Deep Learning Go Brrrr From First Principles What Shapes Do Matrix Multiplications Like? How to Optimize a CUDA Matmul Kernel for cuBLAS-like Performance: a Worklog This post collects various facts I learned from

                                                                  • How the RWKV language model works

                                                                    In this post, I will explain the details of how RWKV generates text. For a high level overview of what RWKV is and what is so special about it, check out the other post about RWKV. To explain exactly how RWKV works, I think it is easiest to look at a simple implementation of it. The following ~100 line code (based on RWKV in 150 lines) is a minimal implementation of a relatively small (430m parame

                                                                    • Julia 1.6: what has changed since Julia 1.0?

                                                                      Julia 1.0 came out well over 2 years ago. Since then a lot has changed and a lot hasn’t. Julia 1.0 was a commitment to no breaking changes, but that is not to say no new features have been added to the language. Julia 1.6 is a huge release and it is coming out relatively soon. RC-1 was released recently. I suspect we have at least a few more weeks before the final release. The Julia Core team take

                                                                      • Why Today’s Python Developers Are Embracing Type Hints | Pyrefly

                                                                        Python is one of the most successful programming languages out there, with it recently overtaking Javascript as the most popular language on GitHub, according to the latest GitHub Octoverse report. The report emphasises the popularity of the language in the growing fields of AI, data science and scientific computing - fields where speedy experimentation and iteration are critical, and where develo

                                                                          Why Today’s Python Developers Are Embracing Type Hints | Pyrefly
                                                                        • The World's Smallest Hash Table | orlp.net

                                                                          This December I once again did the Advent of Code, in Rust. If you are interested, my solutions are on Github. I wanted to highlight one particular solution to the day 2 problem as it is both optimized completely beyond the point of reason yet contains a useful technique. For simplicity we’re only going to do part 1 of the day 2 problem here, but the exact same techniques apply to part 2. We’re go

                                                                          • Scientific Computing in Rust - aftix's dominion

                                                                            While getting my degree in Physics, I had to take classes in both MatLab and Python for scientific computing. I preferred python, where we used the SciPy and NumPy packages. In fact, I used those packages again (along with matplotlib) in an undergraduate research project simulating bacteria films. There's a catch: I was also pursuing a degree in Computer Science, and Python just wasn't fast enough

                                                                            • RWKV-World-V2をPythonから日本語で操作する|shi3z

                                                                              RKWV-World-V2の出来があまりにも良いのでPythonで使う方法をメモっておきます。 基本的にこのGradioの内容をいつものLLMベンチマークの形式にしただけ import os, gc, copy, torch from datetime import datetime from huggingface_hub import hf_hub_download from pynvml import * ctx_limit = 2000 title = "RWKV-5-World-1B5-v2-20231025-ctx4096" os.environ["RWKV_JIT_ON"] = '1' os.environ["RWKV_CUDA_ON"] = '1' # if '1' then use CUDA kernel for seq mode (much faster) from r

                                                                                RWKV-World-V2をPythonから日本語で操作する|shi3z
                                                                              • cuneicode, and the Future of Text in C

                                                                                Following up from the last post, there is a lot more we need to cover. This was intended to be the post where we talk exclusively about benchmarks and numbers. But, I have unfortunately been perfectly taunted and status-locked, like a monster whose “aggro” was pulled by a tank. The reason, of course, is due to a few folks taking issue with my outright dismissal of the C and C++ APIs (and not showi

                                                                                  cuneicode, and the Future of Text in C
                                                                                • Practical SQL for Data Analysis

                                                                                  Pandas is a very popular tool for data analysis. It comes built-in with many useful features, it's battle tested and widely accepted. However, pandas is not always the best tool for the job. SQL databases have been around since the 1970s. Some of the smartest people in the world worked on making it easy to slice, dice, fetch and manipulate data quickly and efficiently. SQL databases have come such

                                                                                    Practical SQL for Data Analysis