content stringlengths 263 5.24M | pred_label stringclasses 1
value | pred_score_pos float64 0.6 1 |
|---|---|---|
package cn.apecode.auth.handler;
import cn.apecode.common.utils.ResponseCode;
import com.alibaba.fastjson.JSON;
import lombok.extern.slf4j.Slf4j;
import org.springframework.security.core.AuthenticationException;
import org.springframework.security.web.AuthenticationEntryPoint;
import org.springframework.stereotype.Com... | __label__POS | 0.818394 |
package cn.apecode.auth.handler;
import cn.apecode.common.utils.ResponseCode;
import com.alibaba.fastjson.JSON;
import lombok.extern.slf4j.Slf4j;
import org.springframework.security.access.AccessDeniedException;
import org.springframework.security.web.access.AccessDeniedHandler;
import org.springframework.stereotype.C... | __label__POS | 0.811605 |
package cn.apecode.common.dto;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModelProperty;
import lombok.Builder;
import lombok.Data;
import org.springframework.security.core.GrantedAuthority;
import org.springframework.security.core.authority.SimpleGrantedAuthority;
import org.... | __label__POS | 0.825531 |
package cn.apecode.common.enums;
import lombok.AllArgsConstructor;
import lombok.Getter;
/**
* @description: 状态码
* @author: apecode
* @date: 2022-05-27 00:25
**/
@Getter
@AllArgsConstructor
public enum StatusCodeEnum {
SUCCESS(1000, "成功"),
UNAUTHORIZED(1001, "请登录"),
USERNAME_PASSWORD_ERROR(1002, "用户名... | __label__POS | 0.975678 |
package cn.apecode.common.exception;
import cn.apecode.common.utils.ResponseCode;
import lombok.extern.slf4j.Slf4j;
import org.apache.catalina.connector.ClientAbortException;
import org.springframework.validation.BindException;
import org.springframework.web.HttpRequestMethodNotSupportedException;
import org.springfra... | __label__POS | 0.869379 |
package cn.apecode.common.utils;
import org.springframework.beans.BeanUtils;
import java.util.ArrayList;
import java.util.List;
/**
* @description: 复制对象或集合工具类
* @author: apecode
* @date: 2022-05-26 13:53
**/
public class BeanCopyUtils {
/**
*@Description: 复制对象
*@Param: source 源
*@Param: targe... | __label__POS | 0.99974 |
package cn.apecode.common.utils;
import com.github.houbb.sensitive.word.bs.SensitiveWordBs;
import com.github.houbb.sensitive.word.support.allow.WordAllows;
/**
* @description: HTML、敏感词工具类
* @author: apecode
* @date: 2022-07-07 18:31
**/
public class HTMLUtils {
private static final SensitiveWordBs WORD_BS =... | __label__POS | 0.800679 |
package cn.apecode.common.utils;
import cn.apecode.common.exception.BizException;
import org.apache.commons.lang3.StringUtils;
import javax.crypto.Cipher;
import javax.crypto.SecretKey;
import javax.crypto.SecretKeyFactory;
import javax.crypto.spec.DESKeySpec;
import java.nio.charset.StandardCharsets;
import java.sec... | __label__POS | 0.985479 |
package cn.apecode.common.utils;
import cn.apecode.common.dto.UserDetailsDto;
import io.jsonwebtoken.Claims;
import io.jsonwebtoken.ExpiredJwtException;
import io.jsonwebtoken.Jwts;
import io.jsonwebtoken.SignatureAlgorithm;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereoty... | __label__POS | 0.885489 |
package cn.apecode.common.utils;
import cn.apecode.common.enums.StatusCodeEnum;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import java.io.Serializable;
import static cn.apecode.common.enums.StatusCodeEnum.FAIL;
import static cn.apecode.common.enums.StatusCodeEnum.SUCCESS;
... | __label__POS | 0.987076 |
package cn.apecode.common.utils;
import cn.apecode.common.dto.IpSourceDto;
import com.alibaba.fastjson.JSON;
import eu.bitwalker.useragentutils.UserAgent;
import org.apache.commons.lang3.StringUtils;
import org.springframework.context.EnvironmentAware;
import org.springframework.core.env.Environment;
import org.spring... | __label__POS | 0.9206 |
package cn.apecode.common.utils;
import org.apache.commons.codec.digest.DigestUtils;
import java.time.LocalDateTime;
import java.time.ZoneId;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
import static cn.apecode.common.enums.ZoneEnum.SHANGHAI;
/**
* @description: 公共工具类
* @author: apecode
* @da... | __label__POS | 0.998865 |
package cn.apecode.common.utils;
import java.util.UUID;
/**
* @description: 随机生成
* @author: apecode
* @date: 2022-06-09 23:33
**/
public class RandomUtils {
/**
* @description: 获得一个UUID
* @param length
* @return {@link String}
* @auther apecode
* @date 2022/6/9 23:34
*/
publi... | __label__POS | 0.999981 |
package cn.apecode.common.utils;
import cn.apecode.common.exception.BizException;
import org.apache.commons.codec.digest.DigestUtils;
import org.apache.commons.lang3.StringUtils;
import java.io.IOException;
import java.io.InputStream;
import java.security.MessageDigest;
import java.util.Objects;
/**
* @description:... | __label__POS | 0.999029 |
package cn.apecode.common.constant;
/**
* @description: Redis前缀名
* @author: apecode
* @date: 2022-05-29 20:17
**/
public class RedisPrefixConst {
// 用户详细信息
public static final String USER_CACHE = "uc";
// 验证码
public static final String USER_CODE_KEY = "code:";
// 验证码过期时间
public static fi... | __label__POS | 1.000006 |
package cn.apecode.common.constant;
/**
* @description: 公共常量
* @author: apecode
* @date: 2022-05-26 13:50
**/
public class CommonConst {
/**
* 否
*/
public static final int FALSE = 0;
/**
* 是
*/
public static final int TRUE = 1;
/**
* 高亮标签
*/
public static fin... | __label__POS | 1.00001 |
package cn.apecode.crypto.handler;
import cn.apecode.crypto.annotation.Decrypt;
import cn.apecode.crypto.config.CryptoConfig;
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springframework.core.MethodParameter;
import org.springframework.core.Ordered;
import org.springframework.cor... | __label__POS | 0.895609 |
package cn.apecode.crypto.utils;
import cn.apecode.common.exception.BizException;
import lombok.extern.slf4j.Slf4j;
import javax.crypto.*;
import java.io.ByteArrayOutputStream;
import java.io.IOException;
import java.nio.charset.StandardCharsets;
import java.security.*;
import java.security.interfaces.RSAPrivateKey;
... | __label__POS | 0.926045 |
package cn.apecode.crypto.utils;
import lombok.extern.slf4j.Slf4j;
import org.bouncycastle.jce.provider.BouncyCastleProvider;
import javax.crypto.Cipher;
import javax.crypto.spec.IvParameterSpec;
import javax.crypto.spec.SecretKeySpec;
import java.nio.charset.StandardCharsets;
import java.security.SecureRandom;
impor... | __label__POS | 0.946592 |
package cn.apecode.config;
import org.apache.catalina.Context;
import org.apache.catalina.connector.Connector;
import org.apache.coyote.http11.Http11NioProtocol;
import org.apache.coyote.http2.Http2Protocol;
import org.apache.tomcat.util.descriptor.web.SecurityCollection;
import org.apache.tomcat.util.descriptor.web.S... | __label__POS | 0.909576 |
package cn.apecode.handler;
import cn.apecode.utils.PageUtils;
import com.aliyun.oss.common.utils.StringUtils;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.springframework.lang.NonNull;
import org.springframework.web.servlet.HandlerInterceptor;
import javax.servlet.http.HttpServletReq... | __label__POS | 0.958424 |
package cn.apecode.handler;
import cn.apecode.common.annotation.AccessLimit;
import cn.apecode.common.utils.ResponseCode;
import cn.apecode.service.RedisService;
import cn.apecode.common.utils.IpUtils;
import com.alibaba.fastjson.JSON;
import org.springframework.data.redis.RedisConnectionFailureException;
import org.s... | __label__POS | 0.844261 |
#!/bin/bash
set -eo pipefail
function getToolConfigValue() {
local var=$1
grep "$var" < "$TOOL_CONFIG" | awk '{print $NF}'
}
# shellcheck disable=SC2034
function setStorageVar() {
TOOL_CONFIG=/etc/datasafed/datasafed.conf
ACCESS_KEY_ID=$(getToolConfigValue access_key_id)
SECRET_ACCESS_KEY=$(getToolConfigV... | __label__POS | 0.934369 |
package cn.apecode.dto;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.experimental.Accessors;
import java.io.Serializable;
import java.util.List;
/**
... | __label__POS | 0.829005 |
package cn.apecode.entity;
import com.baomidou.mybatisplus.annotation.*;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.*;
import java.io.Serializable;
import java.time.LocalDateTime;
/**
* <p>
* 后台菜单
* </p>
*
* @author apecode
* @since 2022-05-26
*/
@Dat... | __label__POS | 0.737204 |
\usepackage{caption}
%----------------------------------------------------------------------------------------
% COMMON
%----------------------------------------------------------------------------------------
\DeclareCaptionFont{fg}{\color{fg}}
\DeclareCaptionFont{accent}{\color{accent}}
%------------------------... | __label__POS | 0.769868 |
\usepackage[most]{tcolorbox}
%----------------------------------------------------------------------------------------
% HIGHLIGHT ENVIRONMENT
%----------------------------------------------------------------------------------------
\newtcolorbox{highlight}{
colback=bg,
colframe=accent,
coltext=fg,
boxrule=... | __label__POS | 0.712156 |
#!/bin/bash
calculate_signature_with_openssl() {
local data="$1"
local sk="$2"
printf "%s" "$data" | openssl dgst -sha1 -hmac "$sk" -binary | base64
}
BINARY_DATA=""
if [ "$ENABLE_ACL" = "true" ]; then
# 26 is request code of GET_BROKER_CONFIG
sig=$(calculate_signature_with_openssl "$ROCKETMQ_USE... | __label__POS | 0.608789 |
// @@@ START COPYRIGHT @@@
//
// Licensed to the Apache Software Foundation (ASF) under one
// or more contributor license agreements. See the NOTICE file
// distributed with this work for additional information
// regarding copyright ownership. The ASF licenses this file
// to you under the Apache License, Version 2... | __label__POS | 0.999009 |
require 'asciidoctor/extensions' unless RUBY_ENGINE == 'opal'
include ::Asciidoctor
# A postprocessor that appends the Google Analytics code to the bottom of the HTML.
#
# Usage
#
# :google-analytics-account: UA-XXXXXXXX-1
#
Extensions.register do
if @document.basebackend? 'html'
# As of Asciidoctor 1.5.2, yo... | __label__POS | 0.761025 |
#!/bin/bash
# shellcheck disable=SC2086
function wait_restore_completion_by_cluster_cr() {
local max_retries=$1
local wait_interval=5
local retries=0
while true; do
cluster_json=$(kubectl get clusters.apps.kubeblocks.io "${CLUSTER_NAME}" -n "${CLUSTER_NAMESPACE}" -o json 2>&1)
kubectl_... | __label__POS | 0.691226 |
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may ... | __label__POS | 0.738417 |
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you ... | __label__POS | 0.708924 |
#!/bin/bash
# log info file
function DP_log() {
msg=$1
local curr_date=$(date -u '+%Y-%m-%d %H:%M:%S')
echo "${curr_date} INFO: $msg"
}
# log error info
function DP_error_log() {
msg=$1
local curr_date=$(date -u '+%Y-%m-%d %H:%M:%S')
echo "${curr_date} ERROR: $msg"
}
# Get file names without extensions ba... | __label__POS | 0.743773 |
local skip_labels = {
["Complete name"] = true,
["CompleteName_Last"] = true,
["Unique ID"] = true,
["File size"] = true,
["Format/Info"] = true,
["Codec ID/Info"] = true,
["MD5 of the unencoded content"] = true,
}
local M = {}
function M:peek()
local image_height = 0
if self:preload() == 1 then
local cac... | __label__POS | 0.684133 |
package ir.apend.slider.ui.Transformers;
import android.support.v4.view.ViewPager;
import android.view.View;
public class VerticalShutTransformer implements ViewPager.PageTransformer{
@Override
public void transformPage(View page, float position) {
page.setTranslationX(-position*page.getWidth());
... | __label__POS | 0.67196 |
package ir.apend.slider.ui.Transformers;
import android.support.v4.view.ViewPager;
import android.view.View;
public class AntiClockSpinTransformer implements ViewPager.PageTransformer {
@Override
public void transformPage(View page, float position) {
page.setTranslationX(-position * page.getWidth());... | __label__POS | 0.76589 |
package ir.apend.slider.ui.Transformers;
import android.support.v4.view.ViewPager;
import android.view.View;
public class HorizontalFlipTransformer implements ViewPager.PageTransformer {
@Override
public void transformPage(View page, float position) {
page.setTranslationX(-position*page.getWidth());
... | __label__POS | 0.634638 |
package ir.apend.slider.ui.Transformers;
import android.content.Context;
import android.support.v4.view.ViewPager;
public class TransformersGroup {
private static final int ANTI_CLOCK_SPIN=1;
private static final int CAROUSEL_EFFECT=2;
private static final int CLOCK_SPIN=3;
private static final int C... | __label__POS | 0.997705 |
package ir.apend.slider.ui.indicators;
import android.content.Context;
import android.os.Build;
import android.support.v4.content.res.ResourcesCompat;
import ir.apend.sliderlibrary.R;
/**
* @author S.Shahini
* @since 11/27/16
*/
public class SquareIndicator extends IndicatorShape {
public SquareIndicator(C... | __label__POS | 0.992738 |
package ir.apend.slider.ui.indicators;
import android.content.Context;
import android.view.Gravity;
import android.view.animation.Animation;
import android.view.animation.ScaleAnimation;
import android.widget.LinearLayout;
import ir.apend.sliderlibrary.R;
/**
* @author S.Shahini
* @since 11/26/16
*/
public abstra... | __label__POS | 0.944858 |
package ir.apend.slider.ui.indicators;
import android.content.Context;
import android.os.Build;
import android.support.v4.content.res.ResourcesCompat;
import ir.apend.sliderlibrary.R;
/**
* @author S.Shahini
* @since 11/27/16
*/
public class RoundSquareIndicator extends IndicatorShape {
public RoundSquareIn... | __label__POS | 0.992655 |
package ir.apend.slider.ui.indicators;
import android.content.Context;
import android.os.Build;
import android.support.v4.content.res.ResourcesCompat;
import ir.apend.sliderlibrary.R;
/**
* @author S.Shahini
* @since 11/27/16
*/
public class CircleIndicator extends IndicatorShape {
public CircleIndicator(C... | __label__POS | 0.991473 |
package ir.apend.slider.ui.indicators;
import android.content.Context;
import android.support.v4.content.res.ResourcesCompat;
import android.widget.LinearLayout;
import ir.apend.sliderlibrary.R;
/**
* @author S.Shahini
* @since 11/27/16
*/
public class DashIndicator extends IndicatorShape {
public DashIndi... | __label__POS | 0.992086 |
package ir.apend.slider.ui.customUI;
/**
* Created by Farzad on 12/17/2016.
*/
import android.content.Context;
import android.graphics.drawable.Drawable;
import android.util.AttributeSet;
import android.view.ViewGroup;
import android.view.ViewParent;
/**
* Created by nuuneoi on 2/17/15 AD.
*/
public class Adjust... | __label__POS | 0.884639 |
package ir.apend.slidersample;
import android.support.v4.content.ContextCompat;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.view.View;
import android.widget.AdapterView;
import java.util.ArrayList;
import java.util.List;
import ir.apend.slider.model.Slide;
import ir.apen... | __label__POS | 0.993889 |
#!/bin/bash
function get_wal_name() {
local fileName=$1
local file_without_ext=${fileName%.*}
echo $(basename $file_without_ext)
}
function fetch-wal-log(){
wal_destination_dir=$1
start_wal_name=$2
restore_time=`date -d "$3" +%s`
pitr=$4
DP_log "PITR: $pitr"
exit_fetch_wal=0 && mkd... | __label__POS | 0.947496 |
# Example ansibleplaybook-signals-and-cancellation
```sh
❯ go run ansibleplaybook-signals-and-cancellation.go
Go-ansible example ──
Go-ansible example ── PLAY [all] *********************************************************************
Go-ansible example ──
Go-ansible example ── TASK [Gathering Facts] *****************... | __label__POS | 0.994364 |
package main
import (
"context"
"fmt"
"os"
"github.com/apenella/go-ansible/v2/pkg/execute"
"github.com/apenella/go-ansible/v2/pkg/execute/workflow"
galaxy "github.com/apenella/go-ansible/v2/pkg/galaxy/role/install"
"github.com/apenella/go-ansible/v2/pkg/playbook"
)
func main() {
ansiblePlaybookOptions := &p... | __label__POS | 0.692042 |
package main
import (
"context"
"fmt"
"os"
"github.com/apenella/go-ansible/v2/pkg/execute"
"github.com/apenella/go-ansible/v2/pkg/execute/workflow"
galaxy "github.com/apenella/go-ansible/v2/pkg/galaxy/collection/install"
"github.com/apenella/go-ansible/v2/pkg/playbook"
)
func main() {
ansiblePlaybookOptions... | __label__POS | 0.642933 |
# Example ansibleplaybook-cobra-cmd
```sh
$ go run ansibleplaybook-cobra-cmd.go --connection-local --playbook site.yml --inventory 127.0.0.1, --extra-var example="Hi! There"
cobra-cmd-ansibleplaybook example ──
cobra-cmd-ansibleplaybook example ── PLAY [all] ***********************************************************... | __label__POS | 0.97627 |
# Example ansibleplaybook-with-executor-time-measurament
```sh
❯ go run ansibleplaybook-with-executor-time-measurament.go
2023-07-27 08:27:45 Go-ansible example ──
2023-07-27 08:27:45 Go-ansible example ── PLAY [all] *********************************************************************
2023-07-27 08:27:45 ... | __label__POS | 0.984435 |
# Example ansibleplaybook-with-timeout
```sh
❯ go run ansibleplaybook-with-timeout.go
Timeout: 15 seconds
Go-ansible example ──
Go-ansible example ── PLAY [all] *********************************************************************
Go-ansible example ──
Go-ansible example ── TASK [Gathering Facts] *********************... | __label__POS | 0.991815 |
package main
import (
"context"
"fmt"
"os"
"os/signal"
"github.com/apenella/go-ansible/v2/pkg/execute"
"github.com/apenella/go-ansible/v2/pkg/execute/configuration"
"github.com/apenella/go-ansible/v2/pkg/execute/result/transformer"
"github.com/apenella/go-ansible/v2/pkg/playbook"
"github.com/fatih/color"
)
... | __label__POS | 0.755481 |
# Example ansibleplaybook-custom-transformer
```sh
❯ go run ansibleplaybook-custom-transformer.go
2023-07-27 08:24:30 Go-ansible example ──
2023-07-27 08:24:30 Go-ansible example ── PLAY [all] *********************************************************************
2023-07-27 08:24:30 Go-ansible example ──
20... | __label__POS | 0.985498 |
#!/bin/bash
declare -a new_shard_pod_fqdns=()
declare -a old_shard_available_pod_fqdns=()
declare -a create_meta_failed_pods=()
function log() {
echo "[$(date)] $*"
}
function execute_sql() {
local pod_fqdn="$1"
local query="$2"
clickhouse-client --user ${CLICKHOUSE_ADMIN_USER} --password ${CLICKHOUSE_ADMIN_... | __label__POS | 0.864012 |
#!/bin/bash
component_name=${instanceName%-*}
instance_fqdn=${instanceName}.${component_name}-headless
function execute_sql() {
local pod_fqdn="$1"
local query="$2"
clickhouse-client --user ${CLICKHOUSE_ADMIN_USER} --password ${CLICKHOUSE_ADMIN_PASSWORD} --host="$pod_fqdn" \
--connect_timeout=2 \
--quer... | __label__POS | 0.666696 |
package transformer
import (
"fmt"
"regexp"
"time"
)
const (
// PrefixTokenSeparator is and string printed between prefix and ansible output
PrefixTokenSeparator = "\u2500\u2500"
// DefaultLogFormatLayout is the default format when is used the LogFormat transformer
DefaultLogFormatLayout = "2006-01-02 15:04:0... | __label__POS | 0.732401 |
{{/*
Library of pods related functions implemented in Bash. Currently, the following functions are available:
- get_pod_list_from_env: Get the list of pods from the provided environment variable.
- min_lexicographical_order_pod: Get the minimum lexicographically pod name from the given pod list.
*/}}
{{/*
This functio... | __label__POS | 0.732798 |
{{/*
Library of string functions implemented in Bash. Currently, the following functions are available:
- is_empty(string): Check if a string is empty.
- equals(string1, string2): Check if two strings are equal.
- split(string, separator): Split a string into an array of strings based on a separator.
- contains(string,... | __label__POS | 0.918692 |
{{/*
Library of common utility functions implemented in Bash. Currently, the following functions are available:
- call_func_with_retry: Call a bash function with retry capability.
*/}}
{{/*
This function is used to execute a Bash function with retry capability.
Usage:
call_func_with_retry <max_retries> <retry_int... | __label__POS | 0.694654 |
/*
Copyright (C) 2022-2025 ApeCloud Co., Ltd
This file is part of KubeBlocks project
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU Affero General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any l... | __label__POS | 0.667262 |
subroutine dc(n, rhs, sol, ipar, fpar, w)
implicit none
integer n, ipar(16)
real*8 rhs(n), sol(n), fpar(16), w(*)
c-----------------------------------------------------------------------
c This a version of Defect Correction Method (DC) implemented
c with reverse communication.
c
c ... | __label__POS | 0.816429 |
SUBROUTINE stream_func_coeffs(depth,hoverd,case,height,currnt,
$ value,n,nstep,num,cosa,sina,coeff,sol,rhs1,rhs2,a,b,ipvt,z,y)
C-----------------------------------------------------------------------
C
C Calculation of steady waves
C
C------------------------------------------------------------------... | __label__POS | 0.716481 |
LDIR = src/functions
# Sources and objects
SOURCES += $(LDIR)/ALLOCATE_Wavefield_Type.f90
SOURCES += $(LDIR)/ASSIGN_IncidentWavefield.f90
SOURCES += $(LDIR)/AnalyticWaveMaker2D.f90
SOURCES += $(LDIR)/BESSH.f90
SOURCES += $(LDIR)/BESSHP.f90
SOURCES += $(LDIR)/BESSJ0.f90
SOURCES += $(LDIR)/BESSJ1.f90
SOURCES += $(LDIR)/... | __label__POS | 0.745616 |
SUBROUTINE polint(xa,ya,n,x,y,dy)
! Polynomial interpolation. Copied form "Numerical Recipes in
! FORTRAN 77"
!
! Bo Terp Paulsen, botp@mek.dtu.dk
INTEGER n,NMAX
INTEGER, PARAMETER :: long=selected_real_kind(12,99)
REAL(KIND=long) dy,x,y,xa(n),ya(n)
PARAMETER (NMAX... | __label__POS | 0.635603 |
/**
* https://github.com/facebook/react-native/blob/master/Libraries/Utilities/differ/deepDiffer.js
*/
'use strict';
/*
* @returns {bool} true if different, false if equal
*/
var deepDiffer = function(one: any, two: any): bool {
if (one === two) {
// Short circuit on identical object references instead of tr... | __label__POS | 0.651759 |
/*
Copyright (C) 2022-2025 ApeCloud Co., Ltd
This file is part of KubeBlocks project
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU Affero General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any l... | __label__POS | 0.871292 |
# ApeRAG 自动化评估功能设计文档
## 1. 概述
本文档旨在为 ApeRAG 设计并实现一个全面的自动化评估功能。该功能的核心目标是允许用户通过自定义的数据集和问题集,对 RAG 应用的效果进行量化评估、跟踪和分析。这将形成一个实验和迭代改进的闭环,帮助用户持续优化他们的 RAG 应用。
### 1.1 核心功能范围 (MVP)
- **问题集管理**: 提供独立的 UI 界面,支持对问题集(包含问题和标准答案)的增删改查及文件上传。
- **问题集自动生成**: 在用户只提供数据集(Collection)的情况下,利用 LLM 从文档中生成事实性问题和推理性问题及其标准答案。
- **评估任务管理**: 用户可以... | __label__POS | 0.705975 |
/*
Copyright (C) 2022-2025 ApeCloud Co., Ltd
This file is part of KubeBlocks project
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU Affero General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any l... | __label__POS | 0.707475 |
/* tslint:disable */
/* eslint-disable */
/**
* ApeRAG API
* ApeRAG API Documentation
*
* The version of the OpenAPI document: 1.0.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
// May c... | __label__POS | 0.910369 |
/* tslint:disable */
/* eslint-disable */
/**
* ApeRAG API
* ApeRAG API Documentation
*
* The version of the OpenAPI document: 1.0.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
/**
* ... | __label__POS | 0.879575 |
/* tslint:disable */
/* eslint-disable */
/**
* ApeRAG API
* ApeRAG API Documentation
*
* The version of the OpenAPI document: 1.0.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
/**
* ... | __label__POS | 0.742205 |
/* tslint:disable */
/* eslint-disable */
/**
* ApeRAG API
* ApeRAG API Documentation
*
* The version of the OpenAPI document: 1.0.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
// May c... | __label__POS | 0.827538 |
/* tslint:disable */
/* eslint-disable */
/**
* ApeRAG API
* ApeRAG API Documentation
*
* The version of the OpenAPI document: 1.0.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
/**
* ... | __label__POS | 0.803342 |
/* tslint:disable */
/* eslint-disable */
/**
* ApeRAG API
* ApeRAG API Documentation
*
* The version of the OpenAPI document: 1.0.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
// May c... | __label__POS | 0.911061 |
/* tslint:disable */
/* eslint-disable */
/**
* ApeRAG API
* ApeRAG API Documentation
*
* The version of the OpenAPI document: 1.0.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
// May c... | __label__POS | 0.745205 |
/* tslint:disable */
/* eslint-disable */
/**
* ApeRAG API
* ApeRAG API Documentation
*
* The version of the OpenAPI document: 1.0.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
// May c... | __label__POS | 0.813362 |
/*
Copyright (C) 2022-2025 ApeCloud Co., Ltd
This file is part of KubeBlocks project
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU Affero General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any l... | __label__POS | 0.645237 |
/* tslint:disable */
/* eslint-disable */
/**
* ApeRAG API
* ApeRAG API Documentation
*
* The version of the OpenAPI document: 1.0.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
// May c... | __label__POS | 0.710414 |
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: Frame.proto
package org.apache.sysds.protobuf;
public final class SysdsProtos {
private SysdsProtos() {}
public static void registerAllExtensions(
com.google.protobuf.ExtensionRegistryLite registry) {
}
public static void registerAl... | __label__POS | 0.782118 |
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you ... | __label__POS | 0.67166 |
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you ... | __label__POS | 0.645555 |
//------------------------------------------------------------------------------
// <auto-generated>
// 此代码由工具生成。
// 运行时版本:4.0.30319.42000
//
// 对此文件的更改可能会导致不正确的行为,并且如果
// 重新生成代码,这些更改将会丢失。
// </auto-generated>
//------------------------------------------------------------------------------
namespace M... | __label__POS | 0.655825 |
//
// SidebarOverlayExampleTests.swift
// SidebarOverlayExampleTests
//
// Created by Alexander Perechnev on 12/24/15.
// Copyright © 2015 Alexander Perechnev. All rights reserved.
//
import XCTest
@testable import SidebarOverlayExample
class SidebarOverlayExampleTests: XCTestCase {
override func setUp()... | __label__POS | 0.901315 |
using MiniTalk.Net;
using System;
using System.Collections.Generic;
using System.Drawing;
using System.Net;
using System.Net.Sockets;
using MiniTalk.Class;
using MiniTalk.Model;
namespace MiniTalk
{
/// <summary>
/// 全局关键数据
/// </summary>
public static class KeyData
{
/// <summary>
... | __label__POS | 0.963608 |
using System;
using System.Collections.Generic;
using System.Drawing;
using System.Linq;
using System.Runtime.InteropServices;
using System.Text;
using System.Threading.Tasks;
namespace MiniTalk
{
public static class WinAPI
{
public const int WM_SYSCOMMAND = 0x0112;
public const int SC_MOVE = ... | __label__POS | 0.912881 |
using MiniTalk;
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
using MiniTalk.Model;
namespace MiniTalk
{
public class ToastAddEventAgs : EventArgs
{
/// <summar... | __label__POS | 0.693562 |
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
namespace MiniTalk
{
public class CBlockQueue<T>
{
protected readonly Queue<T> queue = new Queue<T>();
/// <summary>
/// 入列
/// </summary... | __label__POS | 0.848653 |
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Newtonsoft.Json;
using MiniTalk.Model;
namespace MiniTalk
{
/// <summary>
/// 设置
/// </summary>
public static class Options
{
static Options()
{
_常规设置 = JsonConvert.DeserializeOb... | __label__POS | 0.819165 |
//------------------------------------------------------------------------------
// <auto-generated>
// 此代码由工具生成。
// 运行时版本:4.0.30319.42000
//
// 对此文件的更改可能会导致不正确的行为,并且如果
// 重新生成代码,这些更改将会丢失。
// </auto-generated>
//------------------------------------------------------------------------------
namespace M... | __label__POS | 0.657025 |
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
using System.Drawing;
using System.Threading;
using MiniTalk;
namespace Override_Control
{
public class NameLabel : Label
{
public NameLabel(string name)
... | __label__POS | 0.879904 |
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you ... | __label__POS | 0.671672 |
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you ... | __label__POS | 0.627501 |
/*
* VideoTracker.cpp
*
* Created on: Dec 15, 2017
* Author: zy
*/
#include "VideoTracker.h"
#include "opencv2/opencv.hpp"
#include "tracker.h"
#include "FeatureTensor.h"
using namespace cv;
using namespace std;
VideoTracker::VideoTracker(const DeepSortParam& tracker_params) : params(tracker_params)
{
mod... | __label__POS | 0.652732 |
#include "linear_assignment.h"
#include "hungarianoper.h"
linear_assignment *linear_assignment::instance = NULL;
linear_assignment::linear_assignment()
{
}
linear_assignment *linear_assignment::getInstance()
{
if(instance == NULL) instance = new linear_assignment();
return instance;
}
TRACHER_MATCHD
linear_a... | __label__POS | 0.792636 |
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you ... | __label__POS | 0.824329 |
#include "model.h"
#include <algorithm>
enum DETECTBOX_IDX {IDX_X = 0, IDX_Y, IDX_W, IDX_H };
static void splitStr(const std::string& inputStr, const std::string &key, std::vector<std::string>& outStrVec) {
if (inputStr == "") {
return;
}
int pos = inputStr.find(key);
int oldpos = 0;
if (pos > 0) {
std::str... | __label__POS | 0.777995 |
#include "FeatureTensor.h"
using namespace tensorflow;
FeatureTensor::FeatureTensor(const std::string& model_meta, const std::string& model_data)
: tf_model_meta(model_meta), tf_model_data(model_data)
{
//prepare model:
bool status = init();
if(status == false) exit(1);
}
FeatureTensor::~FeatureTensor()
{
ses... | __label__POS | 0.600853 |
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you ... | __label__POS | 0.899502 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.