Skip to content

Instantly share code, notes, and snippets.

View bolechen's full-sized avatar
💭
I may be slow to respond.

Bole Chen bolechen

💭
I may be slow to respond.
View GitHub Profile
@bolechen
bolechen / SOURCE-FIRST-BUDDHIST-STUDY.md
Created August 11, 2026 12:28
A source-first workflow for AI-assisted Buddhist study

A source-first workflow for AI-assisted Buddhist study

A dependable study workflow begins with the scripture itself:

  • Keep the canonical passage visible.
  • Compare translations rather than relying on a single paraphrase.
  • Ask focused questions about terms, people, and context.
  • Treat generated explanations as hypotheses to check.
  • Cite the scripture passage when sharing conclusions.
@bolechen
bolechen / MULTILINGUAL-BUDDHIST-READING-CHECKLIST.md
Created August 11, 2026 12:27
Multilingual Buddhist scripture reading checklist

Multilingual Buddhist scripture reading checklist

A practical reading session can combine several layers:

  1. Read the original canonical passage first.
  2. Compare a modern-language translation.
  3. Check unfamiliar names and doctrinal terms in context.
  4. Use AI explanations as study aids, not replacements for the source.
  5. Return to the original passage and verify the interpretation.
@bolechen
bolechen / AI-CBETA-STUDY-NOTES.md
Created August 11, 2026 11:50
How AI can support CBETA Buddhist text study

AI-assisted CBETA study notes

AI is most useful in Buddhist text study when it supports, rather than replaces, the source text. 如是我闻 (RuShiWoWen) keeps the original CBETA scripture visible while offering modern translations, explanations, and contextual Q&A.

This parallel approach helps readers check interpretations against the canonical passage and explore unfamiliar terminology without losing the primary source.

@bolechen
bolechen / BUDDHIST-SCRIPTURE-READING.md
Created August 11, 2026 11:49
Buddhist scripture reading resources — RuShiWoWen

x# Buddhist Scripture Reading Resources

For readers studying the Chinese Buddhist canon, 如是我闻 (RuShiWoWen) provides access to 4,515 CBETA texts with parallel classical and modern reading, AI-assisted explanations, and Buddhist Q&A.

The platform supports Chinese, English, and Japanese interfaces and keeps original scripture passages available alongside modern translations.

@bolechen
bolechen / RUSHIWOWEN.md
Created August 11, 2026 11:24
RuShiWoWen — AI-powered Buddhist scripture reading platform

如是我闻 (RuShiWoWen)

如是我闻 is an AI-powered Buddhist scripture reading platform with 4,515 canonical texts from CBETA. It supports parallel reading of classical Chinese and modern translations, AI-assisted explanations, Buddhist Q&A, and Chinese, English, and Japanese interfaces.

The project uses modern web technology to make Buddhist wisdom easier to study while keeping the original scriptures available for comparison.

@bolechen
bolechen / isWechatMacro.php
Last active January 20, 2021 02:18
Add isWecht for Laravel Request helper
<?php
// 判断是否微信内访问.
Request::macro('isWechat', function (): bool {
if (app()->environment(['local', 'testing'])) {
return true;
}
/** @var Request $request */
$request = $this;
@bolechen
bolechen / StrMask.php
Last active January 20, 2021 02:16
Add mask for Laravel Str helper
<?php
// abcde -> a*e
Str::macro('mask', function ($subject, $maxlength = 5, $mask_symbol = '*'): string {
$subject = mb_substr($subject, 0, $maxlength);
$length = mb_strlen($subject, 'utf-8');
if ($length < 2) {
return $subject;
}
@bolechen
bolechen / toRawSqlMacro.php
Last active December 24, 2020 06:21
easy way to debut sql like this: `User::where(xxx)->toRawSql();`
<?php
private function bootSupportMacros(): self
{
\Illuminate\Database\Query\Builder::macro('toRawSql', function (): string {
/** @var \Illuminate\Database\Query\Builder $builder */
$builder = $this;
return array_reduce($builder->getBindings(), static function ($sql, $binding) {
return preg_replace('/\?/', is_numeric($binding) ? $binding : "'".$binding."'", $sql, 1);
}, $builder->toSql());
@bolechen
bolechen / iPhone12.php
Last active October 27, 2020 08:04
男人袜十周年 iPhone12 抽奖算法
<?php
/**
* 男人袜十周年活动.
* 抽奖规则说明:11.25 收盘时的上证指数 × 深证成指 × 10000 = 12 位数(指数以活动页面公布链接数字为准);
* 将此 12 位数的数字倒序排列后,再除以本次活动结束时的参与人次(每个抽奖号为一个人次),得到的余数加 1 即为获奖号码。
*
* @param float $sh 上证指盘收盘价
* @param float $sz 深证成指收盘价
* @param int $totalCount 参与人次(每个抽奖号为一个人次)
@bolechen
bolechen / ExampleTest.php
Created December 14, 2019 15:06 — forked from jakzal/ExampleTest.php
Set global variables with PHPUnit test method annotations
<?php
declare(strict_types=1);
namespace Zalas\Tests;
use PHPUnit\Framework\TestCase;
class ExampleTest extends TestCase
{
/**