This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| 1. # create new .py file with code found below | |
| 2. # install ollama | |
| 3. # install model you want “ollama run mistral” | |
| 4. conda create -n autogen python=3.11 | |
| 5. conda activate autogen | |
| 6. which python | |
| 7. python -m pip install pyautogen | |
| 7. ollama run mistral | |
| 8. ollama run codellama | |
| 9. # open new terminal |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #! /usr/bin/env bash | |
| JENKINS_URL="localhost:8080" | |
| JOB_NAME="YourJobName | |
| USER_NAME="api" | |
| USER_TOKEN="f6706YOURUSERTOKENd2c51" | |
| QUEUE_URL=$(curl --silent "http://${JENKINS_URL}/job/${JOB_NAME}/build" \ | |
| --user "${USER_NAME}:${USER_TOKEN}" \ | |
| --data "token=${JOB_TOKEN}" -XPOST \ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import java.util.regex.Matcher; | |
| import java.util.regex.Pattern; | |
| public class HTMLSpirit{ | |
| public static String delHTMLTag(String htmlStr){ | |
| String regEx_script="<script[^>]*?>[\\s\\S]*?<\\/script>"; //定义script的正则表达式 | |
| String regEx_style="<style[^>]*?>[\\s\\S]*?<\\/style>"; //定义style的正则表达式 | |
| String regEx_html="<[^>]+>"; //定义HTML标签的正则表达式 | |
| Pattern p_script=Pattern.compile(regEx_script,Pattern.CASE_INSENSITIVE); |