阿里巴巴

阿里巴巴

学习资料

  1. 官方课程
    新手必修课
    新手进阶课
    产品发布
    详情页
    阿里巴巴运营之道(推荐第一节课)
  2. 小何在线:AI/人工客服,可解决90%问题
  3. 各地线下培训,但是要求是阿里卖家(有正式账号)

选品

  1. 电池
    半成品,专业性高,出单太慢,门槛高(危险性高,需要国际证书认证)
    刘做电池的原因是她个人从事电池行业
  2. 化妆品
    成品,销量大,有市场,义乌货源多,现成渠道多

货源

  1. 1688.com,应找工厂

发品

类目

参考首页同行类目

标题及关键词

标题及关键词规范

  • 关键词类型:
    Factory direct commercial wooden desk office
    营销词/修饰词:产品卖点、特性、风格。如高级感金色小雏菊耳环
    属性词:用途/认证/案例。
    祛痘痘印凝胶、油污去污清洁神器
    国际大赛铂金奖某地国际珠宝展红蓝宝石复古手链
    某某同款粉色V领毛衣
    核心词:产品本身
    场景词:产品应用场景(?)

  • 寻找流量词:MA->数据分析->引流关键词

  • 核心词为什么放右侧:系统顺序为从右向左检测

产品属性

  • 能填的属性都填上

素材

  1. 图片(主图1+详情页5)
    示例
    ≤3M,正方形,750*750,白底,左上角logo(可有可无)
  2. 视频
    横屏,背景素色或虚化避免干扰
    主图:20-45s,≤100M
    详情页:≤10分钟,≤500M
  3. 产品参数
  4. 公司介绍文案

详情页

详情页排版

其他

  1. 无必要自己拍图/视频,可用别人图/视频

其他

全球旺铺:店铺官网
拍档:阿里官方提供出口通关、退税服务的公司
主账号和子账号:账号共分四种类型:管理员、业务经理、业务员、制作员。
子帐号也就是My Alibaba 操作系统的分帐号权限,包括业务员,业务经理,制作员三种权限区别,由管理员(主账号)创建。
产品权限:
业务员账号:在管理产品的后台,只能看到自己发布的产品
主账号/制作员账号:可以看到全公司的产品
业务经理:能看到自己及其下属发布的产品
SKU: Stock Keeping Unit, 库存量单位。对于电商,一般指单个产品。例如某裤子分为高腰/低腰两类,每类S/M/L,有黑白灰三色,则有2×3×3=18个SKU。
询盘/RTS: 询盘又称询价,是指买方或卖方为了购买或销售某项商品,向对方询问有关交易条件的表示。在国际贸易的实际业务中,一般多由买方主动向卖方发出询盘。可以询问价格,也可询问其他一项或几项交易条件以引起对方发盘,目的是试探对方交易的诚意和了解其对交易条件的意见。
相对于询盘,RTS产品无需询盘,属于可直接下单的标准产品。查看详情
RFQ:
RFQ
RFQ:

  • 客服发起RFQ,会广播至全部卖家,RFQ席位只有10个,占满报价即截止
  • 客户发起RFQ价格较贵,十几美金一条;卖家RFQ报价也有次数限制(防止滥报价),超过则收费
    RFQ是买家委托采购,只限10个供应商报名,满额后就会关闭报价窗口。
    和询盘的区别是RFQ是要通过阿里人工审核后,达到要求的才会发给买家,同时发送给你买家的联系方式;人工审核不过,你是无法知道买家的信息的。
    旺季: 一般每年9~11月为旺季
    优惠补贴:
  • 疫情经济下滑,新店铺有引流政策
  • 新店铺发放¥5000券,用于店铺装修等
  • “中小开”专项补贴:中小企业开拓国际市场专项基金
    金品: Verified Supplier, 阿里巴巴线上线下认证企业。
    长尾词: 非目标关键词但与目标关键词相关的也可以带来搜索流量的组合型关键词。转化率比目标关键词高很多,因为其目的性强。例如关键词“服装”的长尾词:男性服装,女性服装,冬装,夏装等词;以及它的品牌拓展如:某品牌服装等。还有按照质量拓展如:棉类、皮类等。
    FOB/CIF/CFR:
    FOB,离岸价。货物在指定的装运港越过船舷,卖方即完成交货。说明买方必须从这个时候开始承担货物灭失与损坏的一切风险。卖方必须办理货物出口相关手续。FOB仅适用于海运、内河运输。
    CIF,成本+保险+运费。意思是货物的总价格,除了货物本身的价值之外,还包括保险,和至目的地港口运费。这些是要卖家出的。除了特殊约定,一切按照最低价投险。
    CFR,Cost and Freight,成本+运费。卖方负责运输,买方购买保险。
    一件代发
    作为卖家,哪怕你只卖出一件产品,供应商也可以帮你发货。有订单了就去采购发货,没有订单也不会有囤货压货的风险。什么是一件代发
Redis

Redis

What is redis

An distributed in-memory key-value database.
distributed: redis can scale from a single instance to a distributed system.
in-memory: that’s why redis is fast and commonly serves as cache.
key-value: redis stores key-value pairs.

Why redis

As an in-memory cache, redis is much faster than traditional RDBMS.
Helps reduce database workload.

Install

Server: See offical install procedure here.
As no offical windows install file provided, tporadowski provides an unoffical install file.

Client: redis server ships with a cli tool redis-cli. For GUI client, check RedisInsight out.

Config

Difference between redis.windows-service.conf and redis.windows.conf

redis.windows-service.conf: Configuration file for windows service.
reids.windows.conf: Configuration file for command line.

Security

Default redis requires no auth, but cannot access from machine other than localhost.
To enable remote access (only tested on windows):
In file redis.windows-service.conf:

  1. Comment bind 127.0.0.1(line 64). This makes redis listen to all interfaces.
  2. Change procted-mode yes to protected-mode no(line 83). All clients are now able to connect in.
  3. Uncomment requirepass foobared(line 503) and replace foobared to your own password.

Use

Different types

Type Description
Hash Key-value dictionary object.
Sorted Set Sorted set.
Set Unsorted set.
String Simplest type. String or number.
List Linked list under the hood. Can add element to the head/left or the tail/right.
JSON JSON object. Requires RedisJSON module be installed.

Commands

redis-cli: connects to localhost on port 6379.
redis-cli -h [host] -p [port] -a [password]: connect to specified host and port. If password contains special character, wrap it in quotes.

node redis

Note that redis does not work in browser environment.

Single threaded and asynchronous Javascript

Reference:

  1. A conclusion of Javascript running mechanism
  2. Detailed explanation of Javascript asynchronism
  3. JavaScript Event Loop And Call Stack Explained

Sinle-threaded Javascript

A running chrome consists of multiple process. Each tab is an isolated process.
chrom task manager
A tab process consisits of multiple threads. Among them the important ones includes:

  1. Rendering thread. Renders DOM.
  2. Javascript engine thread. Runs Javascript. Note that when Javascript engine thread runs, rendering thread hangs. Because Javascript engine thread can manipulate DOM and rendering requires a consistent DOM.
  3. Event thread. Handles event loop.
  4. Timer thread. Handles timer methods like setTimeout, setInterval. Timer thread should be stand-alone as running of other function may affect timing accuracy.

Asynchronism

Javascript, well-known for its asynchronism.
Synchronous functions runs and gets result. When function is slow (e.g. has file I/O or web request operations), it waits.
Asynchronous functions runs and expects result. The function does not wait for result, instead it leaves a callback function there to handle future result, and it moves on.
Asynchronism makes Javascript run without idle time. That’s why javascript is fast.

Event loop and call stack

Event loop and call stack
Browsers gives us Web APIs to handle callbacks. Functions like AJAX, setTimeout call these APIs.
Web APIs push callbacks into callback queue. Callbacks wait to be executed in the future.
Event loop watches call stack and callback queue. If call stack is empty, event loop takes one callback from callback queue and javascript engines executes the callback.

Queues

Callback queue is not only one but two queue: macrotask queue and microtask queue.
Everytime event loop is triggered, it takes all microtasks and one macrotask. Microtasks are executed first.
Macrotasks: setTimeout, setInterval, setImmediate, I/O operations, UI rendering
Microtasks: Promise, process.nextTick, MutationObserver

Markdown

Markdown

What is markdown ?

A lightweight markup language which formats content by its simple syntax.

Why markdown ?

  1. Eveywhere, for everything.
    Websites like Reddit, Github, etc. support markdown. Documents, notes, books, emails and so on support markdown. WYSIWYG files are mostly only supported by its own editor.

  2. Human readable. Markdown files are in plain text which is human readable. WYSIWYG files are not.

  3. Portable. As markdown files are written in plain text, it can be created on any device, any operating system. And almost all platforms supports rendering of markdown.

Kicking the tires

Online editor: Dillinger
Client editor: Marktext, a realtime rendering editor

Syntax

Basic

Element Syntax
Heading # Heading 1
## Heading 2
### Heading 3
Bold **bold text**
Italic *Italic*
Blockquote > blockquote
List 1. First Item
2. Second Item
3. Third Item
- First Item
- Second Item
- Third Item
Code `code`
Horizontal rule ---
Link [title](https://www.example.com)
Image ![alt text](image.jpg)

Extended

Element Syntax
Table | Syntax | Description |
| ———– | ———– |
| Header | Title |
| Paragraph | Text |
Note that there must be a blank line after the table.
Fenced code block ```{ firstname: ‘dongtian’, lastname: ‘chen’ }```

Use ``` [language] to specify code block language, for example ``` js to specify javascript. See supported language here
Footnote Here’s a sentence with a footnote. [^1]
[^1]: This is the footnote.
Definition List term
: definition
Strikethrough ~~The world is flat.~~
Task List - [x] Write the press release
- [ ] Update the website
- [ ] Contact the media
Emoji That is so funny! 😂
Highlight I need to highlight these ==very important words==.
Subscript H~2~O
Superscript X^2^

FAQ

  • Escaping
    Use backslash to escape most special characters.

  • Leading spaces
    Markdown does not support leading spaces before each paragraph. Use  (may have some problem with specific renderer like Hexo) or full-width space(a prettier solution) at the beginning.

  • Custom style
    Use html tags directly in markdown and style them with css.
    1
    2
    3
    4
    5
    6
    7
    > <div class="poetry">满堂花醉三千客,一剑霜寒十四州。</div>

    <style>
    .poetry {
    text-align: center;
    }
    </style>

  • Warning box
    The easiest way is to use emojis:
1
>  **If you are using mobile browser**: Be very careful here!

Use emoji to call user attention


  • Change line in blockquote
1
2
3
4
5
6
7
8
9
10
11
12
13
> Case 1
>
> 00:23
>
> 00:54
>
> &nbsp;
>
> Case 2
>
> 00:21
>
> 00:51

will produce:

Case 1

00:23

00:54

&nbsp;

Case 2

00:21

00:51

or an easier one(leave one space at the beginning of the second line and so on):

1
2
3
> line 1
line 2
line 3

will produce:

line 1
line 2
line 3


  • Highlight delete/add line in code

Use diff directive:

1
2
3
``` diff
- I like markup
+ I like markdown

gives:

1
2
- I like markup
+ I like markdown

  • List in list/nested list

Use 2 or 4 spaces:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
# Unordered list

* Item 1
* Item 2
* Item 3
* Item 3a
* Item 3b
* Item 3c

# Ordered list

1. Step 1
2. Step 2
3. Step 3
1. Step 3.1
2. Step 3.2
3. Step 3.3
Git

Git

What is Git ?

A distributed version control system.

Why Git over SVN ?

  1. Github uses git. Most modern IT companies use git.
  2. Git is distributed, SVN is centralized. Git enables you to work and source control offline with your own repo.
  3. Most operations are done locally, so it’s fast.

How Git works

Git consists of 4 areas:

  1. Working Directory: Current working directory.
  2. Staging Area: Tracks and saves changes ready to commit.
  3. Local Repo: Repository on the disk.
  4. Remote Repo: Repository on the server.

Git areas

Concepts

  • HEAD: Current branch.

.gitignore file

Refs:

  1. Git ignore patterns
  2. gitignore

Patterns

Pattern Example matches Explanation
logs logs
logs/debug.log
logs/latest/foo.bar
build/logs
build/logs/debug.log
If you don’t append a slash, the pattern will match both files and the contents of directories with that name. In the example matches on the left, both directories and files named logs are ignored
logs/ logs/debug.log
logs/latest/foo.bar
build/logs/foo.bar
build/logs/latest/debug.log
Appending a slash indicates the pattern is a directory. The entire contents of any directory in the repository matching that name – including all of its files and subdirectories – will be ignored
logs/* logs/test.log(a file)
logs/test(a directory)
but not
logs/bar/hello.c(a file)
the asterisk in the pattern does not match “bar/hello.c” which has a slash in it.
logs/
!logs/important.log
logs/debug.log
logs/important.log
Wait a minute! Shouldn’t logs/important.log be negated in the example on the left? Nope! Due to a performance-related quirk in Git, you can not negate a file that is ignored due to a pattern matching a directory
logs/**/debug.log logs/debug.log
logs/monday/debug.log
logs/monday/pm/debug.log
A double asterisk matches zero or more directories.
logs/*day/debug.log logs/monday/debug.log
logs/tuesday/debug.log
but not
logs/latest/debug.log
Wildcards can be used in directory names as well.
logs/debug.log logs/debug.log
but notdebug.log
build/logs/debug.log
Patterns specifying a file in a particular directory are relative to the repository root. (You can prepend a slash if you like, but it doesn’t do anything special.)

FAQ

What is HEAD in git ?

The HEAD in Git is the pointer to the current branch reference, which is in turn a pointer to the last commit you made or the last commit that was checked out into your working directory.

Git reset

Ref

Suppose we have a branch master with A/B/C commits:
- A - B - C (master)

  • reset --soft B: Moves pointer to B; changes staged; run commit and will get a new commit as C
  • reset --mixed B: Default. moves pointer to B; changes remain but unstaged; run add and commit and will get a new commit as C
  • reset --hard B: Moves pointer to B; changes permanently reset; always run status to make sure changes can be discarded

Undo a commit

undo add: git reset
undo commit: git reset --hard HEAD~1 (moves to one commit before and --hard resets staging and working changes)

  • In existing directory, git init .
  • git remote add origin <remote repo url>(origin is a conventional name for remote repo)
  • git push origin <local branch name>

What is a leading slash in .gitignore ?

The leading slash anchors the match to the root.

How can I ignore everything but one file in a directory ?

Original Answer

1
git add -f Website\bin\Settings.json

What is fast-forward ?

Fast forward

Git pull and git fetch

  • Ref: Fetch vs pull
  • Git pull: Incorporates changes from a remote repository into current branch and then fast-forward/merge current branch.
  • Git fetch: If don’t want to fast-forward/merge, use this.
  • pull = fetch + merge

Branches

  • git branch
    Show all local branches, with current branch marked with an asterisk.

    1
    2
    * master
    Pages
  • git branch -r
    Show all remote branches.

    1
    2
    origin/HEAD -> origin/master  // Currently checked out branch, which is origin/master
    origin/master
  • git branch -a
    List all branches.

  • git branch newb
    Create new branch named newb.

  • git checkout newb
    Switch to branch newb.

  • git checkout -b newb
    Shorthand for git branch newb and git checkout newb.

  • git branch -d newb
    Delete local branch newb.